core-plot

Change color plot symbol at index - CorePlot

有些话、适合烂在心里 提交于 2019-12-12 05:54:55
问题 I try add label of plot symbol when user touch at plot symbol. How to change color this plot symbol,too. Here i my code to add label of plot symbol - (void)scatterPlot:(CPTScatterPlot *)plot plotSymbolWasSelectedAtRecordIndex (NSUInteger)index { if(symbolTextAnnotation) { [graph.plotAreaFrame.plotArea removeAnnotation:symbolTextAnnotation]; [symbolTextAnnotation release]; symbolTextAnnotation = nil; } if ([(NSString *)plot.identifier isEqualToString:@"TOTAL"]) { // Setup a style for the

Don't Display the Axis line in bar chart using core plot

痴心易碎 提交于 2019-12-12 05:39:02
问题 i dont want show Axis line in bar graph view. i want to show only the bar plot how can i remove that Axis line? that is whenever i run the application its showing XY Axis but where i can remove for wont display that Axis line. i cant add image so i added code here see my code here: - (void)generateData { NSMutableDictionary *dataTemp = [[NSMutableDictionary alloc] init]; //Array containing all the dates that will be displayed on the X axis dates = [NSArray arrayWithObjects:@"A", @"B", @"C", @

ios sub view appears upside down in simulator

允我心安 提交于 2019-12-12 04:08:00
问题 I have created an activity indicator and a label below it in a uiview sub class and calling it in many different tabs.It works as intended in most of the places i'm calling it except in Graph Hosting views(CPTGraphHostinView). In this particular view the subView appears to be upside down.The label goes above the spinner.I tried with imageview instead of label, and its the same upside down image. Here is my initWithframe method - (id)initWithFrame:(CGRect)frame { self = [super initWithFrame

unable to show anything on x-axis and y-axis labels in core-plot

社会主义新天地 提交于 2019-12-12 04:00:03
问题 I'm using core plot in an application and from past one week I am trying to show labels on x-axis and y-axis. But haven't succeed yet. I'm posting my code here with screen shot. If someone knows any solution to fix the problem let me know urgently. Code - -(void)viewDidLoad { [super viewDidLoad]; // Initialize all graph dependent data. //self.dataForPlot = [[NSMutableArray alloc] initWithCapacity:0]; minYValues = [[NSMutableArray alloc] initWithCapacity:0]; maxYValues = [[NSMutableArray alloc

iOS Core Plot “Function transformation” - Y axis only origin

廉价感情. 提交于 2019-12-12 03:53:48
问题 I cannot find how to do this for a while now, my graph is drawn ok every time but I want to move up my graph, like when you have f(x) + n . So, what I want to do actually is change Y origin, so I can draw my (x,0) points. I do not want to draw my points on X axis, I do not see the line that good. I want that my zero Y point actually starts at point three, but not to transform the graph at the same time. Here is picture of what I want to do (see the green line and Y point): 回答1: The plot space

Touching a multiple plotsymbol in core plot and get the two touch plot symbol index

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-12 03:00:30
问题 I want to get the difference between two points touched simultaneously. But i am only getting one index into scatter plot by this method, -(void)scatterPlot:(CPTScatterPlot *)plot plotSymbolWasSelectedAtRecordIndex:(NSUInteger)idx withEvent:(CPTNativeEvent *)event; How to get two index by multitouch? 回答1: The built-in interaction methods only support one point at a time. You can get the coordinates of the touch points, convert them to the coordinate space of the plot area layer, and use the

Core Plot - set zoom level to show only part of graph

橙三吉。 提交于 2019-12-12 02:48:32
问题 I'm having this Plot: Every tick on the X-axis represents a day in the calendar. But as you can see, the date is very hard to read so I would like to set the the zoom level to show only 7 days instead of 11 (like right now). Please see screenshot below: But it's important to have more data available, so users can scroll to the left and there will still be dates shown. How would I do that? Thanks in advance. 回答1: You need to set the xRange and globallXRange properties to get work. plotSpace

Coreplot: Axis Labels Fixed Location

陌路散爱 提交于 2019-12-12 02:26:22
问题 I'm trying to customize a Coreplot graph in many ways I can and the next thing I would like to do is place the X Axis Labels (one that is custom as well) at the bottom of the graph, independent of the X axis' position (whether it's scrolled up or down). To make it clear, it is similar to giving the labels an offset value of something like 50.0. But offset is not the property I'm looking for since it fixes the labels location relative to the X axis. Any way this can be done? Or do I have to

CorePlot; How to skip data when using doubleForPlot instead of numberForPlot

╄→尐↘猪︶ㄣ 提交于 2019-12-11 23:26:37
问题 I have a CPTScatterPlot with a huge amount of data. I have found that I could reduce the memory overhead (and thus time) by using doubleForPlot instead of numberForPlot in CorePlot. But when using numberForPlot I have the option to return nil if some data are missing. CorePlot will then make a break in the graph and not connect the neighbor points. Is the same possible when using doubleForPlot ? Is there some exceptional value that I can return and the CorePlot will treat this as a missing

Core Plot Gradient bars

五迷三道 提交于 2019-12-11 20:58:48
问题 I am using core plot to create my graphs. I want to have a gradient in my bars so that the colour starts at yellow and changes to red. However this depends on how high the bar is. The graphs for example should look as follows: I am using the image on the far right (tallest one) within the application. However there are 2 issues. 1) The bar's are upside down. So they start with red and go up to yellow. 2) The bar's are totally red if I use an image that's too large. If I use an image that is