core-plot

CorePlot in Swift can not call “numberForPlot”

拜拜、爱过 提交于 2020-02-22 11:04:42
问题 I am using CorePlot(https://github.com/core-plot/core-plot) in Swift. In order to make a pie chart on iOS, I wrote as below by translating Obj-C code to swift. I was able to view the graph title, but I could not plot a pie chart. As a result of looking at NSlog, I found that “numberForPlot” function was apparently not called. How should I rewrite this? My code looks like this: ViewController.swift import UIKit class ViewController: UIViewController, CPTPieChartDataSource, CPTPieChartDelegate{

CorePlot in Swift can not call “numberForPlot”

家住魔仙堡 提交于 2020-02-22 11:01:00
问题 I am using CorePlot(https://github.com/core-plot/core-plot) in Swift. In order to make a pie chart on iOS, I wrote as below by translating Obj-C code to swift. I was able to view the graph title, but I could not plot a pie chart. As a result of looking at NSlog, I found that “numberForPlot” function was apparently not called. How should I rewrite this? My code looks like this: ViewController.swift import UIKit class ViewController: UIViewController, CPTPieChartDataSource, CPTPieChartDelegate{

CorePlot in Swift can not call “numberForPlot”

我怕爱的太早我们不能终老 提交于 2020-02-22 10:57:32
问题 I am using CorePlot(https://github.com/core-plot/core-plot) in Swift. In order to make a pie chart on iOS, I wrote as below by translating Obj-C code to swift. I was able to view the graph title, but I could not plot a pie chart. As a result of looking at NSlog, I found that “numberForPlot” function was apparently not called. How should I rewrite this? My code looks like this: ViewController.swift import UIKit class ViewController: UIViewController, CPTPieChartDataSource, CPTPieChartDelegate{

CorePlot: unable to change pie chart position (displacement)

▼魔方 西西 提交于 2020-01-25 12:39:10
问题 I am unable to change the pie chart position (I would like it to be more left in respect to the legend so that the legend does not overlay the pie chart). Basically I would like to shift it towards the left to allow the legend to display. I tried modifying the following properties (but with no apparent effect on the pie graph position): // pieChartGraph is a CPTPieChart object pieChartGraph.graph.position = CGPointMake(-100, 0); // I also tried: pieChart.position = CGPointMake(-100, 0); //

how to draw 3D pie chart using core-plot in ipad? [closed]

混江龙づ霸主 提交于 2020-01-24 09:48:04
问题 It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 8 years ago . I have to draw 3D pie chart in ipad using core-plot API .how can i do it ? Please advise . 回答1: Core Plot is 2-D only. You can create simulated 3-D effects on pie charts using shadows and/or an overlay fill. See

Not able to plot 3 graphs in 3 different views using core-plot iOS

只谈情不闲聊 提交于 2020-01-17 03:11:07
问题 I am using core-plot library to plot a graph in 3 different view..Problem is among all of 3 only 3rd graph get displayed correctly...But if I draw each graph separately then they always shows up right..Any clue would be of great help .Thanks //In ViewWillAppear -(void) viewWillAppear:(BOOL)animated { dataPoints = [[NSMutableArray alloc]init]; // Create graph from theme CPTgraph1 = [(CPTXYGraph *)[CPTXYGraph alloc] initWithFrame:CGRectZero]; CPTTheme *theme = [CPTTheme themeNamed

iOS Core Plot - Scatter plot symbol color appearance

China☆狼群 提交于 2020-01-17 01:42:04
问题 I am using CorePlot for Scatter plot and would like to know how to obtain the circles of the scatter plot with such a color effect as it is here http://i.stack.imgur.com/7ZcqY.jpg I would like to get the color as in CPTXYScatterPlot - Can I set the Z order of plot symbols?. 回答1: In your symbolForScatterPlot implementation, create a circlePlotSymbol with a gradient fill, like so: CPTPlotSymbol *circlePlotSymbol = [CPTPlotSymbol ellipsePlotSymbol]; // Obviously for a real bubble chart you'll

how to restrict scrolling for +ve part in cpxygraph

谁说胖子不能爱 提交于 2020-01-16 18:50:08
问题 I am new to core plot SDK, implemented core plot in my app. i need to restrict -ve part of graph. i.e always i will have +ve values for graph((1,1),(10,15),(20,15)).i need horizontal , vertical scrolling for +ve part only.So i want to restrict remaining 3 parts of graph. I tried in all ways help less, so posted here. if any one already done with this type requirement, please help me ASAP. Thanks in advance. 回答1: The easiest way to restrict the scrolling ranges is to set the globalXRange and

how to restrict scrolling for +ve part in cpxygraph

烈酒焚心 提交于 2020-01-16 18:49:13
问题 I am new to core plot SDK, implemented core plot in my app. i need to restrict -ve part of graph. i.e always i will have +ve values for graph((1,1),(10,15),(20,15)).i need horizontal , vertical scrolling for +ve part only.So i want to restrict remaining 3 parts of graph. I tried in all ways help less, so posted here. if any one already done with this type requirement, please help me ASAP. Thanks in advance. 回答1: The easiest way to restrict the scrolling ranges is to set the globalXRange and

Can/How Core-Plot extrapolate scatter points to fit fixed labeling policy?

若如初见. 提交于 2020-01-16 12:45:22
问题 Situation: Scatter points/date, each month could contain a variable-number of data (points). Desired: Have fixed-width months along x-axis whose columns contain their respective points (i.e. same-number of points/month). Can Core-Plot extrapolate missing data points to equalize the distribution of data/month? How would that be done? I want the fixed-width months to coincide/sync with their respective data points (and hence, may necessitate the filling in of missing data points; i.e., months