Closed GoogleCodeExporter closed 8 years ago
[deleted comment]
I took a closer look at this today and I now disagree that this is an issue.
This is how I understand the algorithm:
A candlestick plot takes four data values: open, close, high, and low. The open
and close are used to determine whether the candlestick is "increasing" or
"decreasing". If the close is higher than the open it is "increasing",
otherwise it is "decreasing". The open value (at least for real stock market
data) might be equal to the previous close, but it doesn't have to be and often
is not. An open value exactly equal to the close is a special case—the
candlestick will just be a single horizontal line.
Core Plot allows you to set the increasing and decreasing fills and border line
styles so you can use any color scheme desired.
Original comment by eskr...@mac.com
on 6 Sep 2012 at 12:29
We can not using one set of data "open, close, high, and low" to determine the
candlestick is "increasing" or "decreasing", except the first day of the data(
Because it has not previous data).
Increasing <--- it is not meaning TODAY's Close > TODAY's OPEN, it is meaning
TODAY's CLOSE > PREVIOUS's CLOSE.
But i personally edit the function "drawCandleStickInContext", i think we may
be need to change as this one -->
-(void)drawCandleStickInContextNEWNEWNEW(CGContextRef)context x:(CGFloat)x
open:(CGFloat)open close:(CGFloat)close high:(CGFloat)high low:(CGFloat)low
alignPoints:(BOOL)alignPoints previousx:(CGFloat)previousx
previousopen:(CGFloat)previousopen previousclose:(CGFloat)previousclose
previoushigh:(CGFloat)previoushigh previouslow:(CGFloat)previouslow;
<-- Candle Stick should not be showing a Individual Value in each Candlestick.
Every Candle Stick should be have a relationship with the previous one, like
the following :
if( Current Close > Previous CLOSE)
{
color = RED;
}
else if( Current Close < Previous CLOSE)
{
color = BLACK;
}
else if ( Current Close == Previous CLOSE)
{
color= Previous Candle stick color
}
Original comment by nullmi...@gmail.com
on 6 Sep 2012 at 1:55
Can you provide a reference for that algorithm? Everything I've found describes
a candlestick plot the way Core Plot does it now--the day's open and close
determine the color of the candle.
Original comment by eskr...@mac.com
on 6 Sep 2012 at 10:42
Closing this issue due to lack of information. The current implementation in
Core Plot follows the normal practice for this type of plot.
Original comment by eskr...@mac.com
on 4 Nov 2012 at 7:50
Original issue reported on code.google.com by
nullmi...@gmail.com
on 4 Sep 2012 at 2:36