Thanks
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Market Analyzer column question
Collapse
X
-
Market Analyzer column question
Hi..Is it possible to create within Market Analyzer a column that shows what percent last price is from 52 week high. i.e. 52 week high 100, last 95, column displays -5.00%.
ThanksTags: None
-
Hello derivtrader,
Thank you for the post.
Yes that is possible. As a starting point you could review the existing High52Weeks column in the NinjaScript editor. That would be how to get the 52 week high metric from a column. You could duplicate this script as well if you wanted to just start with that code in a script.
Next you would need to create a double variable and store the 52 week high.
Finally during the OnMarketData events you could observe the MarketDataType.Last events and during those events calculate the price using the variable and current market price. (See LastPrice column code).
The calculated value can then be set to CurrentValue.
I look forward to being of further assistance.
JesseNinjaTrader Customer Service
-
Jesse thank you for the reply. Unfortunately above my minimal programming knowledge. Was hoping for a solution using properties configuration.
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Net Change
by Segwin
Started by Segwin, 05-07-2018, 02:15 PM
|
14 responses
1,789 views
0 likes
|
Last Post
by aligator
Today, 11:47 AM
|
||
Started by Jimmyk, 01-26-2018, 05:19 AM
|
6 responses
837 views
0 likes
|
Last Post
by emuns
Today, 11:27 AM
|
||
Started by jxs_xrj, 01-12-2020, 09:49 AM
|
6 responses
3,294 views
1 like
|
Last Post
by jgualdronc
Today, 10:56 AM
|
||
Started by Touch-Ups, Today, 10:36 AM
|
0 responses
13 views
0 likes
|
Last Post
by Touch-Ups
Today, 10:36 AM
|
||
Started by geddyisodin, 04-25-2024, 05:20 AM
|
11 responses
63 views
0 likes
|
Last Post Today, 10:08 AM |
Comment