Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I'm not quite clear on what you mean by "days back" but will explain how it works.
On a chart we can see the values of every indicator for all days back from the current date.
When the same indicators run on RadarScreen, it also runs through all the same days as it does on a chart but we normally can only see the values on the last bar, which should be the same as the values on the last bar on the chart. But you can use a print statement to print the values on any dates you want. Here is a simple example:
if Date = 1220502 or // Print values on 5/2/22
Date = 1220627 or // Print values on 6/27/22
Date = 1230515 then // Print values on 5/15/23
Print(ELDateToString(Date), Indicator1:10:2, Indicator2:10:2, Indicator3:10:2);
Thank you for your response and for providing the sample code.
Regarding Days Back, it is about settings, and the attached image here is for chart settings, but we would like to make these settings on the radar screen.
I understand. Here is the code I use to stop the RadarScreen calculations at some date in the past.
It ends up with the RadarScreen display looking exactly like it did on the past date you select.
I leave the StopDate input set at a far future date ("12/31/30") to keep RadarScreen displaying
the values of today but would set it to "6/5/20" to stop the calculations on that date.
if Active then begin // Actve is TRUE until calculations are stopped by reaching StopDate
StopPlots = LastBarOnChart or (Active and Date >= LastDate); // Stop calculations on LastDate
// Your code here
if StopPlots then Active = FALSE;
end; // if Active
The attached image here is the result of executing the following code with Interval set to 1 minute and trying to get the data of the past opening price,
I tried the chart and the radar screen and the chart shows the past opening price without any problem, but the radar screen seems to return -1 as the result of the execution.
Is it possible to get the same results on the radar screen as on the chart?
2023-06-27 chart settingsDays Back(Running results on chart and radar screen)
There is no way I know of to have RadarScreen stop running at some past date or time.
The code I posted earlier is a way I wrote code to tell it to stop calculating at some past date or time.
This requires you to put the code for the indicator are using in the code I posted.
please keep in mind that Radarscreen will only load the minimum number of bars by default for performance reasons. If you need additional history (which you do for all indicators using historical data in the calculations) Radarscreen has an option to load additional data:
So, for example, if 24 hours is represented by 1 minute, it would be 1440 minutes, so would it be possible to get the opening price of the previous day by going back before 1440 bars?