11 lines
317 B
Python
11 lines
317 B
Python
|
from pyFTS.models import chen
|
||
|
from pyFTS.partitioners import Grid, Entropy, Util as pUtil
|
||
|
from pyFTS.data import Bitcoin
|
||
|
train = Bitcoin.get_data()
|
||
|
fs = Grid.GridPartitioner(data=train, npart=50)
|
||
|
model = chen.ConventionalFTS(partitioner=fs)
|
||
|
model.fit(train[:-10])
|
||
|
print(model)
|
||
|
forecasts = model.predict(train[-10:])
|
||
|
|