X-axis action strange - Charts iOS The Next CEO of Stack OverflowIs there a good charting library for iPhone?Scaling Axis in iOS Charts (MPAndroidChart for iOS)iOS Charts - set minimum y axis rangeHow to render only chosen axis labels in ios ChartsiOS Charts - Objective C, not SwiftMultiple labels xAxis iOS-Chartsios-charts combined chart: bars going past right axis of chartiOS Charts: Combined data into stacked bar chart?Formatting bar chart x-axis values, bars, and labelHow to create a custom limit line label in candlestick chart using ios-charts library?
Multiple labels for a single equation
What connection does MS Office have to Netscape Navigator?
Is there an analogue of projective spaces for proper schemes?
How do we know the LHC results are robust?
Which kind of appliances can one connect to electric sockets located in a airplane's toilet?
MessageLevel in QGIS3
Real integral using residue theorem - why doesn't this work?
How to safely derail a train during transit?
Why didn't Khan get resurrected in the Genesis Explosion?
How to count occurrences of text in a file?
How did people program for Consoles with multiple CPUs?
How does the mv command work with external drives?
How did the Bene Gesserit know how to make a Kwisatz Haderach?
Anatomically Correct Strange Women In Ponds Distributing Swords
Elegant way to replace substring in a regex with optional groups in Python?
Is "for causing autism in X" grammatical?
How do I go from 300 unfinished/half written blog posts, to published posts?
How do I avoid eval and parse?
Would a completely good Muggle be able to use a wand?
I believe this to be a fraud - hired, then asked to cash check and send cash as Bitcoin
What is the result of assigning to std::vector<T>::begin()?
Several mode to write the symbol of a vector
Can you replace a racial trait cantrip when leveling up?
Bold, vivid family
X-axis action strange - Charts iOS
The Next CEO of Stack OverflowIs there a good charting library for iPhone?Scaling Axis in iOS Charts (MPAndroidChart for iOS)iOS Charts - set minimum y axis rangeHow to render only chosen axis labels in ios ChartsiOS Charts - Objective C, not SwiftMultiple labels xAxis iOS-Chartsios-charts combined chart: bars going past right axis of chartiOS Charts: Combined data into stacked bar chart?Formatting bar chart x-axis values, bars, and labelHow to create a custom limit line label in candlestick chart using ios-charts library?
I'm using the Charts library on iOS, but I'm having troubles with one of my charts in my TableView. The X-axis looks strange, and I loose resolution in my data. Here is how it currently looks:
My data is typically between 900 and 1100.
I configured the chart like this:
let dataSet = LineChartDataSet(values: entries, label: "")
dataSet.drawCirclesEnabled = false
dataSet.lineWidth = 2
dataSet.mode = .horizontalBezier
dataSet.colors = UIColor.gray
dataSet.drawValuesEnabled = false
let lineChartData = LineChartData(dataSets: [dataSet])
self.chartEntries.append(lineChartData)
Any ideas on why my X-axis looks like this? My others charts look fine and dandy.
ios swift charts tableview ios-charts
add a comment |
I'm using the Charts library on iOS, but I'm having troubles with one of my charts in my TableView. The X-axis looks strange, and I loose resolution in my data. Here is how it currently looks:
My data is typically between 900 and 1100.
I configured the chart like this:
let dataSet = LineChartDataSet(values: entries, label: "")
dataSet.drawCirclesEnabled = false
dataSet.lineWidth = 2
dataSet.mode = .horizontalBezier
dataSet.colors = UIColor.gray
dataSet.drawValuesEnabled = false
let lineChartData = LineChartData(dataSets: [dataSet])
self.chartEntries.append(lineChartData)
Any ideas on why my X-axis looks like this? My others charts look fine and dandy.
ios swift charts tableview ios-charts
Can you show me your data or where r u assigning those data in chart ?
– CodeChanger
Mar 12 at 8:49
add a comment |
I'm using the Charts library on iOS, but I'm having troubles with one of my charts in my TableView. The X-axis looks strange, and I loose resolution in my data. Here is how it currently looks:
My data is typically between 900 and 1100.
I configured the chart like this:
let dataSet = LineChartDataSet(values: entries, label: "")
dataSet.drawCirclesEnabled = false
dataSet.lineWidth = 2
dataSet.mode = .horizontalBezier
dataSet.colors = UIColor.gray
dataSet.drawValuesEnabled = false
let lineChartData = LineChartData(dataSets: [dataSet])
self.chartEntries.append(lineChartData)
Any ideas on why my X-axis looks like this? My others charts look fine and dandy.
ios swift charts tableview ios-charts
I'm using the Charts library on iOS, but I'm having troubles with one of my charts in my TableView. The X-axis looks strange, and I loose resolution in my data. Here is how it currently looks:
My data is typically between 900 and 1100.
I configured the chart like this:
let dataSet = LineChartDataSet(values: entries, label: "")
dataSet.drawCirclesEnabled = false
dataSet.lineWidth = 2
dataSet.mode = .horizontalBezier
dataSet.colors = UIColor.gray
dataSet.drawValuesEnabled = false
let lineChartData = LineChartData(dataSets: [dataSet])
self.chartEntries.append(lineChartData)
Any ideas on why my X-axis looks like this? My others charts look fine and dandy.
ios swift charts tableview ios-charts
ios swift charts tableview ios-charts
edited Mar 12 at 7:44
MetaSnarf
4,16611332
4,16611332
asked Mar 8 at 14:27
RecusiweRecusiwe
20111437
20111437
Can you show me your data or where r u assigning those data in chart ?
– CodeChanger
Mar 12 at 8:49
add a comment |
Can you show me your data or where r u assigning those data in chart ?
– CodeChanger
Mar 12 at 8:49
Can you show me your data or where r u assigning those data in chart ?
– CodeChanger
Mar 12 at 8:49
Can you show me your data or where r u assigning those data in chart ?
– CodeChanger
Mar 12 at 8:49
add a comment |
1 Answer
1
active
oldest
votes
The chart looks fine, since it's trying to squeeze your data that's around value 1000 into a very small space. If you have a look at the MPAndroidChart lib wiki, you can see that you can adjust the min and max range per axis, so you can effectively zoom in closer to your values to better see the distribution:
setAxisMaximum(float max): Set a custom maximum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
setAxisMinimum(float min): Set a custom minimum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
It would look something like:
graph.yAxis.axisMinimum = 900
graph.yAxis.axisMaximum = 1100
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55065216%2fx-axis-action-strange-charts-ios%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
The chart looks fine, since it's trying to squeeze your data that's around value 1000 into a very small space. If you have a look at the MPAndroidChart lib wiki, you can see that you can adjust the min and max range per axis, so you can effectively zoom in closer to your values to better see the distribution:
setAxisMaximum(float max): Set a custom maximum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
setAxisMinimum(float min): Set a custom minimum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
It would look something like:
graph.yAxis.axisMinimum = 900
graph.yAxis.axisMaximum = 1100
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
add a comment |
The chart looks fine, since it's trying to squeeze your data that's around value 1000 into a very small space. If you have a look at the MPAndroidChart lib wiki, you can see that you can adjust the min and max range per axis, so you can effectively zoom in closer to your values to better see the distribution:
setAxisMaximum(float max): Set a custom maximum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
setAxisMinimum(float min): Set a custom minimum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
It would look something like:
graph.yAxis.axisMinimum = 900
graph.yAxis.axisMaximum = 1100
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
add a comment |
The chart looks fine, since it's trying to squeeze your data that's around value 1000 into a very small space. If you have a look at the MPAndroidChart lib wiki, you can see that you can adjust the min and max range per axis, so you can effectively zoom in closer to your values to better see the distribution:
setAxisMaximum(float max): Set a custom maximum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
setAxisMinimum(float min): Set a custom minimum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
It would look something like:
graph.yAxis.axisMinimum = 900
graph.yAxis.axisMaximum = 1100
The chart looks fine, since it's trying to squeeze your data that's around value 1000 into a very small space. If you have a look at the MPAndroidChart lib wiki, you can see that you can adjust the min and max range per axis, so you can effectively zoom in closer to your values to better see the distribution:
setAxisMaximum(float max): Set a custom maximum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
setAxisMinimum(float min): Set a custom minimum value for this axis.
If set, this value will not be calculated automatically depending on
the provided data.
It would look something like:
graph.yAxis.axisMinimum = 900
graph.yAxis.axisMaximum = 1100
answered Mar 8 at 15:20
AdisAdis
2,58522130
2,58522130
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
add a comment |
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh right. So I can just set the max to the highest datapoint + a constant, and min for the lowest datapoint + a constant to get the right zoom?
– Recusiwe
Mar 8 at 18:17
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
Oh, I can see I use a CombinedChart, and I dont seem to be able to access the axis' in the same manner?
– Recusiwe
Mar 8 at 18:40
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
I don't see why. Use a lineChart instead since you don't have any combined data.
– Adis
Mar 9 at 13:56
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55065216%2fx-axis-action-strange-charts-ios%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Can you show me your data or where r u assigning those data in chart ?
– CodeChanger
Mar 12 at 8:49