1
我下面的生成代码散点图点:我需要显示的X和Y轴的主要和次要线和散点图显示核心,情节
- (void)viewDidLoad
{
[super viewDidLoad];
[self generateDataSamples];
CPTGraphHostingView *hostingview=[[CPTGraphHostingView alloc] initWithFrame:self.view.bounds];
[self.view addSubview:hostingview];
graph=[[CPTXYGraph alloc] initWithFrame:self.view.bounds];
hostingview.hostedGraph =graph;
CPTScatterPlot *datasourceLinePlot =[[CPTScatterPlot alloc] init];
datasourceLinePlot.dataSource =self;
[graph addPlot:datasourceLinePlot];
[datasourceLinePlot release];
[graph release];
[hostingview release];
}
输出如下:
但是,我需要为x和yaxis显示majorline和minorline ...!
像这样y-0.5,1.0,1.5 ....!和x-0.5,1.0,1.5 ...!
我要输出如下图:
任何一个与我帮助....!
谢谢......!