[QuantSchool] Fit two different curves one onto another
Posted: Sat Apr 20, 2024 6:42 pm
The main way I map two curves together is pretty simple.
this technique is important if you want to put RSI on price data for instance.
First use Standardization on the data you want to fit to the destination data
then multpiply it by the volatility filter you used in the standardization (usually Standart Deviation) but with the volatility of the *destination* data
and simply add the standardized data to the moving average of the destination curve
so pseudo code would be like this :
MrTools please could you tell us more ways to do that ?
I think there are "OnChart" RSIs and CCIs but I didn't look into the code.
I would really appreciate you dissecting these codes and explaining how they work that would be amazing
Jeff
this technique is important if you want to put RSI on price data for instance.
First use Standardization on the data you want to fit to the destination data
then multpiply it by the volatility filter you used in the standardization (usually Standart Deviation) but with the volatility of the *destination* data
and simply add the standardized data to the moving average of the destination curve
so pseudo code would be like this :
Code: Select all
double sourceData[];
double destinationData[];
data1[] = (sourceData[] - MA(sourceData)) / StdDev(sourceData)
result[] = MA(destinationData) + data1[] * StdDev(destinationData)
I think there are "OnChart" RSIs and CCIs but I didn't look into the code.
I would really appreciate you dissecting these codes and explaining how they work that would be amazing
Jeff