This is a migrated thread and some comments may be shown as answers.

Plotting a point inside TKChartCandlestickSeries

2 Answers 24 Views
Chart
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Leo
Top achievements
Rank 1
Leo asked on 15 Dec 2014, 02:21 PM
I am using an licensed version of Telerik from my clients account. I would like to know is there any way to plot a point inside the box in the candlestick graph?

2 Answers, 1 is accepted

Sort by
0
Pavel Pavlov
Telerik team
answered on 16 Dec 2014, 10:08 AM
Hi,
I guess the white points come with coordinates or some data series . 

The best way to render them is to add a second series over the candlestick series ( e.g. a TKChartLineSeries). 
This way you can precisely set where the white dots appear .
Additionally you will need to hide the line and maybe adjust the size/shape of the white points  in the line series.

Sample code bellow. 
//series is a TKChartLineSeries instance
//Make points white , round and small
series.style.pointShape = [[TKPredefinedShape alloc] initWithType:TKShapeTypeCircle andSize:CGSizeMake(4, 4)];
TKChartPaletteItem *pointPaletteItem = [[TKChartPaletteItem alloc] init];
pointPaletteItem.fill = [TKSolidFill solidFillWithColor:[UIColor whiteColor]];
TKChartPalette *pointPalette = [[TKChartPalette alloc] init];
[pointPalette addPaletteItem:pointPaletteItem];
series.style.shapePalette = pointPalette;
  
//Hide the line NS  leave only the points visible.
series.style.fill = [TKSolidFill solidFillWithColor:[UIColor clearColor] ];
series.style.stroke = [TKStroke strokeWithColor:[UIColor clearColor] ];

In case you have troubles implementing this approach , just let me know and I will  gather a small sample for you .

Regards,
Pavel Pavlov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Leo
Top achievements
Rank 1
answered on 16 Dec 2014, 10:39 AM
Hi Team, thank you for the response. I instead used scatter chart along with the candlestick. It served the purpose. Thank you.
Tags
Chart
Asked by
Leo
Top achievements
Rank 1
Answers by
Pavel Pavlov
Telerik team
Leo
Top achievements
Rank 1
Share this question
or