Jump to content
Medved Trader Forums

Mike Medved

  • Posts

  • Joined

  • Last visited

  • Days Won


Mike Medved last won the day on July 22

Mike Medved had the most liked content!


116 Excellent


About Mike Medved

Contact Methods

  • Website URL

Profile Information

  • Gender

Recent Profile Visitors

8,731 profile views
  1. .fctbNone{ color:#000000; } .fctbStyle5{ color:#0000ff; } .fctbStyle3{ color:#ff00ff; } .fctbStyle1{ color:#a52a2a; } .fctbStyle6{ color:#808080; } .fctbStyle2{ color:#008000; } .fctbStyle4{ color:#000000;font-weight:bold;text-decoration:underline; }int DayNumber = -1; public void MainCalculation() { if (TradingDay.DayNumber != DayNumber) { CurrentState.AHVol = 0; CurrentState.RegVol = 0; DayNumber = TradingDay.DayNumber; } if (TradingDay.IsAfterHours) CurrentState.AHVol += BarVolume; else CurrentState.RegVol += BarVolume; SetColor("Line Color", SysColor.MainIndicator1); SetYValue(CurrentState.RegVol==0?0:CurrentState.AHVol*100/CurrentState.RegVol); } /// <summary> /// Is called at start of paintbar calculation, should be used to initialize anything needed for the paintbar /// </summary> private void PaintbarInitialize() { CurrentState.AHVol = 0; CurrentState.RegVol = 0; } /// <summary> /// Holds paintbar state - fill with variables needed to be preserved for next paintbar calc /// </summary> private struct PaintbarState { public double AHVol; public double RegVol; } /// <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 /// </summary> private void PaintbarClearState() { CurrentState = new PaintbarState(); } /// <summary> /// Saves paintbar state (called internally). /// </summary> private void PaintbarSaveState() { SavedState = CurrentState; } /// <summary> /// Restores paintbar state (called internally). /// </summary> private void PaintbarRestoreState() { CurrentState = SavedState; } In fact you can use the same paintbar as a scan - just set the SetScanResult as well as the SetYValue. Isn't MedvedTrader fun?
  2. You can make a paintbar that would plot the % of after hour volume compared to regular hour volume. It would not show you a # but it would show a line with a scale.
  3. We have an API. It's a streaming websocket/JSON API, you connect to running MT and can get market data, trade, set up alerts, get notified when alerts fire, etc. https://docs.google.com/document/d/15IvYQEYzSeftTSEdVhsptAguM0fGm9mTJFSDDAK7zWE ... which reminds me I gotta finish prettying the doc up.
  4. When you delete symbols from a portfolio, the feed should stop (unless there is another portfolio that has the symbol, of if there is a chart up for the symbol and "Active Chart Subscription" option is checked in settings). The easy way to check is to bring up a raw data window for the symbol. That window is passive, it does not actively subscribe to the symbol, so you can see if data is coming in from some window by seeing if the raw data window updates.
  5. Well if you're doing > that's not CrossesUp, that's just >. And yes, if you use index of 1 it will check the candle before the last one, so that way you will be checking after the close of the candle.
  6. We didnt change anything on that recently. We'll ask TDA people about it.
  7. Interesting. Does the description "lag" the symbol or is it completely random?
  8. Ok I repeated it. Will go look what's up. Fixed will be in next beta.
  9. Note that TimestampEnd is the timestamp of the last tick in the candle. So for timed candles it may not be 1 min (or 5 min etc) after the candle start. It may be 30 sec or something. Depending on the ticks that go into the candle.
  10. Where do you modify the price of the alert - in the alert editor?
  11. Added: TimestampEnd indexed variable - like Timestamp. Will be in next beta.
  12. Looked at your files, don't see anything... There is a condition in MT where if you draw too fast (that is click move and release within a fraction of a second) it won't draw but that's not what is happening is it?
  13. So - other than the current time - what do you need? When you look at a renko bar, there is a start time and an end time. You want to know the end time for the bar?
  14. DateTime.UtcNow I think is what you're looking for. But that of course is current UTC time, so it would only work for the last candle processing, not for going back.
  15. Ah Completely misunderstood your request. No, not storing it. Will see.
  • Create New...