Jump to content
Medved Trader Forums

Mike Medved

Administrators
  • Posts

    1,542
  • Joined

  • Last visited

  • Days Won

    124

Everything posted by Mike Medved

  1. The alert level shows with 4 decimals. BUT when the alert triggers the "value" that is passed to you in API is the price of the stock at the time the alert triggered. Also - take a look at the new "Price Alerts" indicator. It shows the Price alerts that are set in the Alert system (not the trendline alerts, just the regular price alert system) on the chart. Since you are not using a slanted trendline for your alerts, maybe that's a simpler alternative.
  2. The "value" that is shown is the price of the stock at the time of the alert (I am not sure why the 0.41 is there when the cross down is below that though). Was the value of the stock at the time the alert triggered NOT 2 dec places?
  3. Export your scan, send it to me - I will look what's wrong. support@medvedtrader.com
  4. IB's market data feeds..... don't get me started.
  5. See my edited response above.
  6. Well from their definition, the raindrop charts need intraday data. They cannot work on historical data. You need volume at each price level. Also I made it so that these candles don't take into account OHLC backfilled data because the one-minute OHLC data is very non-granular. Jerry pointed out though that for your purposes OHLC data would work, so I put that in. Will be in next version.
  7. Also: the SetInterVar and GetInterVar are now available in the Websocket API. Which means that the API will be able to read values set by Paintbars or set values that paintbars can read and use in their calculations or display on charts.
  8. Tommy, I did the following (I put this in our Help file): You can now use hotkeys and paintbars together to enhance functionality. The way to do this is: * Create a Paintbar or a Scan that calculates some value that you would want to use in your Hotkey when placing a trade. * Use the SetInterVar or the SetChartVar function to pass that value out of the paintbar. * Use the passed value in any hotkey by using the intervar() or chartvar() scripting function in any field The difference between intervar and chartvar values is that the intervar values are per-symbol. That is, a chart's paintbar may set it, but a hotkey may access it on a different chart, or even on a trade ticket or a Level II window. The chartvar value is only available to the hotkey on the chart where you placed the particular paintbar. If you want to test it, email us and we will point you to an exe that has it.
  9. I missed having that value. Added it. It will be the Type and it will be 0 through 7 - (the values will be in the (?) description) // 0 = Strong Climax Churn // 1 = Strong Climax // 2 = Strong Churn // 3 = Weak Climax Churn // 4 = Weak Climax // 5 = Weak Churn // 6 = Low Volume // 7 = Regular
  10. You can make a paintbar, Advanced mode, using Vix Fix get its value into let's say VixFix and then do SetColor("Color", Color.Green); SetYValue(-VixFix); and then display the paintbar.
  11. Hotkeys really have access to the current state of your account and current state of the symbol being referenced. Not the historical data or various computed indicators on the symbol. But I am thinking I can allow paintbars to set a named variable in the chart that would be accessible by any hotkey executed on that chart. That way you could compute any value you wanted based on any indicator and expose it to the hotkey.
  12. Then an intraday scan with a "Better Volume" indicator is in order. You cannot put two scans - historical *and* intraday on one portfolio. But you can duplicate the portfolio, with the same source, and run one scan on one portfolio and the other on the other.
  13. Well, I display the LULD value as soon as I receive it from QM Try asking QM whether they can do this more timely.
  14. Here is a paintbar that would do it (aren't paintbars neat?) .fctbNone{ color:#000000; } .fctbStyle5{ color:#0000ff; } .fctbStyle7{ color:#000000; } .fctbStyle3Style7{ color:#000000; }double High30 = 0; double Low30 = Double.MaxValue; double X1 = -1; double X2 = -1; public void MainCalculation() { if (Timestamp[0].Minute % 30 == 0 || X1==-1) { High30 = High; Low30 = Low; X1 = CandleNumber; X2 = X1+0.5; } else { High30 = Math.Max(High30, High); Low30 = Math.Min(Low30, Low); X2 = CandleNumber+0.5; } SetLine(X1+0.1, SysColor.Positive, X1,High30,X2,High30); SetLine(X1+0.2, SysColor.Negative, X1,Low30,X2,Low30); }
  15. You can calculate previous day's volume as follows (in Advanced mode). In the following CurrentState.PrevDayVolume always holds the previous day's volume. The bolded parts in the below code are the parts that are different from the standard template state code that is generated automatically in advanced mode. public void MainCalculation() { if ( CurrentState.DayNumber != TradingDay.DayNumber ) { CurrentState.PrevDayVolume = CurrentState.TodayVolume; CurrentState.TodayVolume = 0; CurrentState.DayNumber = TradingDay.DayNumber; } CurrentState.TodayVolume += BarVolume; } /// <summary> /// INITIALIZES paintbar. Is called at start of paintbar calculation, should be used to initialize anything needed for the paintbar /// NOTE: do NOT initialize the CurrentState here - the PaintbarClearState will be called AFTER this call, and will wipe it out. /// </summary> private void PaintbarInitialize() { } /// <summary> /// Holds paintbar state - fill with variables needed to be preserved for next paintbar calc /// </summary> private struct PaintbarState { public double PrevDayVolume; public double TodayVolume; public int DayNumber; } /// <summary> /// Holds current PB state - use to calc PB, changes to it carry over to next PB calc /// </summary> private PaintbarState CurrentState; /// <summary> /// Holds saved PB state - internal /// </summary> private PaintbarState SavedState; /// <summary> /// Is called at start of paintbar calculation, should be used to clear the paintbar state /// and initialize whatever variables you place into it. This is called AFTER PaintbarInitialize /// </summary> private void PaintbarClearState() { CurrentState = new PaintbarState(); CurrentState.DayNumber = -1; } /// <summary> /// Saves paintbar state (called internally). /// </summary> private void PaintbarSaveState() { SavedState = CurrentState; } /// <summary> /// Restores paintbar state (called internally). /// </summary> private void PaintbarRestoreState() { CurrentState = SavedState; }
  16. Well... If we can repeat it we can definitely fix it. Can you send me your setup (Help/Send Settings) mention this thread and I will try doing it with exactly your stuff.
  17. Ok just did exactly that. With Stockwatch as a source. It got increased then got decreased. Any linked charts with an active subscription that you have that may have open that kept that IBM running?
  18. DayRange would show you DayHigh - DayLow. What does it show for you?
  19. Hm ok it would be good if you could try to repeat it consistently, with steps. Like - start, add a few symbols, switch ports that kind of stuff. We tried and couldn't.
  20. I didn't expose that value because not all feeds have that data... Volume24 is for crypto. It is the volume in the previous 24 hours. Constantly changes.
  21. ? in the ribbon menu, on the Main tab there is a Source selection box. If you need to set up a different source's login that is in Settings / Data Sources / Configure Accounts
  22. zemuss, to add to Jerry's answer: the paintbar operates on the candles that are calculated either in the chart or inside the scan for that particular candle frequency. That dataset would have to be calculated twice or more and in case of paintbars would make no sense - because when you're operating on a 3 min candle and you check a 20 min candle data, how do you match the candles? Here is an exercise that can possibly be done to combine 5m and 15m candles in one scan though it is a bit complicated. 1. Make two portfolios. Identical. Same source. Run them. 2. Run a scan on one portfolio with 15m candle that calculates some value and then uses the SetInterVar function with whatever that value is. Or several values. 3. Run a different scan on the second portfolio on 5m candles, and use GetInterVar function to get the values from the 15m candle run to use.
  23. No they definitely do not update as you go backwards. Any SymbolData values are current values. If you want to keep track of things like that yourself, efficiently, you need to switch to doing Advanced (I guess you already are) and use the StateFIFOQueue machinery with the state-keeping. Here's an example (obviously this is for historical chart) I will bold the lines that are not just filler: .fctbNone{ color:#000000; } .fctbStyle4{ color:#0000ff; } .fctbStyle2{ color:#008000; } .fctbStyle2Style4{ color:#0000ff; } .fctbStyle2Style3{ color:#000000; } .fctbStyle6{ color:#808080; } .fctbStyle3{ color:#000000; }StateFIFOQueue HighLow; public void MainCalculation() { HighLow.Add(High); HighLow.Add(Low); double High52, Low52; HighLow.GetHighLow(out High52, out Low52); // at this point High52 has the 52 week high, Low52 has 52 week low } /// <summary> /// INITIALIZES paintbar. Is called at start of paintbar calculation, should be used to initialize anything needed for the paintbar /// NOTE: do NOT initialize the CurrentState here - the PaintbarClearState will be called AFTER this call, and will wipe it out. /// </summary> private void PaintbarInitialize() { } /// <summary> /// Holds paintbar state - fill with variables needed to be preserved for next paintbar calc /// </summary> private struct PaintbarState { } /// <summary> /// Holds current PB state - use to calc PB, changes to it carry over to next PB calc /// </summary> private PaintbarState CurrentState; /// <summary> /// Holds saved PB state - internal /// </summary> private PaintbarState SavedState; /// <summary> /// Is called at start of paintbar calculation, should be used to clear the paintbar state /// and initialize whatever variables you place into it. This is called AFTER PaintbarInitialize /// </summary> private void PaintbarClearState() { CurrentState = new PaintbarState(); HighLow = new StateFIFOQueue(520); // double of 260 } /// <summary> /// Saves paintbar state (called internally). /// </summary> private void PaintbarSaveState() { SavedState = CurrentState; HighLow.SaveState(); } /// <summary> /// Restores paintbar state (called internally). /// </summary> private void PaintbarRestoreState() { CurrentState = SavedState; HighLow.RestoreState(); }
  24. 1. Not a US broker 2. Do they have an API? 3. If they contact us, we'd think about it
×
×
  • Create New...