Giter VIP home page Giter VIP logo

Comments (3)

jinglescode avatar jinglescode commented on May 27, 2024

Hi @feuerstarta,

Do check out Why isn't my Model Performing?.

Because the market dipped and recovered within a month or two, this has never happened in history. Since you are using 80/20, the model does not have the chance to learn that pattern.

Also, this is a very simple model, feel free to tweak the model, for better performance. Try building more features on the data as well, possibly adding "difference from previous day".

from time-series-forecasting-tensorflowjs.

feuerstarta avatar feuerstarta commented on May 27, 2024

See that still makes no sense to be a flat line. the flat line means it is not taking any of the input of the unseen_x into the account. If you do a full predict on the 0-100% of the 80/20 learn, it predicts value till the 80% mark then just flatlines from the last predicted number. If you keep that 100% prediction and do 90/10 split it will go to the 90% mark then flatlines at the 90% mark with the last predicted value. This is showing that the model works only for the section it trains and can not do a prediction period as the model only reports the last recorded train.

from time-series-forecasting-tensorflowjs.

jinglescode avatar jinglescode commented on May 27, 2024

This is the challenge of machine learning, that a model, out of the box, doesn't work for all kinds of data. There is a lot of parameter tuning involve. There may need to do more feature engineering. Or there is a need to change the model architecture.

Doing a quick search, you can see that you are not the only one who faced this problem:

I do not have an answer for you, unfortunately. Some suggestions would be:

  • try tweaking the normalize the data portion (.div(tf.scalar(10) might be causing problems line 19 and 20)
  • include more data features, maybe can include volume as well
  • include more data features, maybe trading indicators such as MACD, RSI, Bollinger bands
  • build another model architecture

I'm working on a Python version.

from time-series-forecasting-tensorflowjs.

Related Issues (11)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.