Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Creating Dollar Index
Collapse
X
-
ok thanks, I understand that you can pay to get the dollar index but wouldn't it be a cheaper/more convenient option to create your own indicator
with the option of adding your own symbols & weightings? (even better if we could plot a formula (or ratio) in NT8)
e.g. majors formula: USDEUR * USDGBP * USDAUD * USDNZD * USDCAD * USDCHF * USDJPY
e.g. emerging formula: USDCNH * USDZAR * USDNOK * USDSEK * USDRUB
and a similar exercise for any other index/ratio you wish to createLast edited by dibDab; 05-30-2023, 02:44 AM.
Comment
-
I'd be happy to make a start on a community indicator?
1. Find similar script to base it on e.g. https://ninjatraderecosystem.com/use...ownload/ratio/ (anyone know of something better for NT8?)
2. Keep it simple
3. Decide what parameters would work (without getting into parsing complex math formula)
e.g.
MSFT performance against S&P
parameter "Top" = MSFT
parameter "Bottom" = S&P 500
Dollar Index
parameter "Top" Top = 50.14348112 x USDEUR^0.576 x USDJPY^0.136 x USDGBP^-0.119 x USDCAD^0.091 x USDSEK^0.042 x USDCHF^0.036
(if USD is not the base value in the currency cross, the exponent weighting would be negative e.g. EURUSD^-0.576).
parameter "Bottom" = 1 (set to 1 if left blank)
evaluate then plot v = Top / Bottom
... something like that, all suggestions welcome!Last edited by dibDab; 05-31-2023, 06:17 AM.
Comment
-
Hi, I'd love to be able to use a community US Dollar indicator. I don't know how to code this, but I just read an 2015 article (see below) that has a formula that might work:
"The DJ FXCM US Dollar Index makes use of a more straightforward methodology based on 4 currencies in equal amounts – AUD, JPY, GBP, and EUR at 25% each."
Thoughts on this?
Comment
-
Hello dibDab,
I am not aware of any existing index or indicator with this specific logic. You could create a custom indicator for this.
Instruments can be added with AddDataSeries().
https://ninjatrader.com/support/help...dataseries.htm
In BarsInProgress 0, the Value[0] plot would be set to Closes[1][0] * Closes[2][0] * Closes[3][0], etc.
https://ninjatrader.com/support/foru...er#post1182264
trdrJajaja, Welcome to the NinjaTrader forums!
Below is a link to a forum post with helpful resources on getting started with NinjaScript and C#.
https://ninjatrader.com/support/foru...pts#post786040Chelsea B.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by AgriTrdr, 07-16-2023, 12:54 PM
|
32 responses
266 views
0 likes
|
Last Post
by f.saeidi
Yesterday, 06:49 AM
|
||
Started by Mestor, Today, 03:15 AM
|
0 responses
1 view
0 likes
|
Last Post
by Mestor
Today, 03:15 AM
|
||
Started by Mestor, 03-10-2023, 01:50 AM
|
11 responses
305 views
0 likes
|
Last Post
by z.franck
Today, 02:29 AM
|
||
Started by Padan, Today, 02:02 AM
|
0 responses
6 views
0 likes
|
Last Post
by Padan
Today, 02:02 AM
|
||
Started by bukowa, 11-09-2023, 06:07 PM
|
20 responses
409 views
0 likes
|
Last Post
by Adfra
Today, 01:36 AM
|
Comment