Coder Social home page Coder Social logo

resample_to_interval about technical HOT 5 CLOSED

freqtrade avatar freqtrade commented on May 4, 2024
resample_to_interval

from technical.

Comments (5)

xmatthias avatar xmatthias commented on May 4, 2024 1

Your issue is this:

    # EMA - Exponential Moving Average """
    dataframe['ema55_htf'] = ta.EMA(dataframe_htf, timeperiod=55)
    dataframe['ema120_htf'] = ta.EMA(dataframe_htf, timeperiod=120)
    dataframe['ema233_htf'] = ta.EMA(dataframe_htf, timeperiod=233)

you assign the EMA of the resampled timeframe to the non-resampled, which is a much longer dataframe, so the values don't match and are in the wrong position.

Assign all values for the resampled timeframe to dataframe_htf and merge them after that (which you already do, based on the strategy shared on slack).

The merge-statement will change the name slightly (in your case, you'll need to compare (dataframe['resample_240_ema55_htf'] > dataframe['ema233']) &)...

from technical.

hroff-1902 avatar hroff-1902 commented on May 4, 2024 1

@blinklabllp here is how to insert code fragments into github issues properly (for readability): https://help.github.com/en/articles/creating-and-highlighting-code-blocks#fenced-code-blocks

I cannot edit the other's posts at this repo...

from technical.

blinklabllp avatar blinklabllp commented on May 4, 2024

Thanks for the info, I have tired to fix the code post above.

Also now when I merge it back, I will be able to access the dataframe['resample_240_ema55_htf'] in the order calls?

from technical.

xmatthias avatar xmatthias commented on May 4, 2024

well yes - but the name will depend on the resample interval (the 240 in that stands for the minutes you resampled to, so 4 * 60 for 4h intervals).

from technical.

blinklabllp avatar blinklabllp commented on May 4, 2024

Gotcha, thanks a lot helping me out.

from technical.

Related Issues (20)

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.