Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Indicator on Indicator 'TInput TOutput not matched' #121

Open
andyb1979 opened this issue Feb 13, 2021 · 1 comment
Open

Indicator on Indicator 'TInput TOutput not matched' #121

andyb1979 opened this issue Feb 13, 2021 · 1 comment

Comments

@andyb1979
Copy link

andyb1979 commented Feb 13, 2021

Hi there!

Does Trade support indicators on indicators?

If I try this ->

var rsi = new RelativeStrength(PrimaryPriceData, 14).Compute();
var emaOnRsi = new ExponentialMovingAverage<AnalyzableTick<decimal?>, AnalyzableTick<decimal?>>(rsi, tick => tick.Tick, 9).Compute();

Then I get an exception

System.ArgumentException: 'TInput, TOutput not matched!'
at Trady.Analysis.Infrastructure.AnalyzableBase`4..ctor(IEnumerable`1 inputs, Func`2 inputMapper)

Any ideas?

@ridicoulous
Copy link
Contributor

ridicoulous commented Feb 13, 2021

Take a look here .
If you map AnalyzableTick<decimal?> to IOhclv, it should work, I think.
Like rsi.Compute().Select(c=> new Candle(c.DateTime, c.Tick, c.Tick....)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants