Could not draw x-axis scale in Logarithmic format #4371
Closed
rajanbabu033
started this conversation in
General
Replies: 2 comments 3 replies
-
Your XAxis defaults to be categorical. Try changing to Also if you could throw this into a sandbox it would be easier to help with |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I'm using recharts and would like to render x-axis scale for line chart as 100, 1K, 10K.But it is rendering as 200, 300, 400, 600, 800, 10000.......8000
Actual Chart:
X-axis scale is rendered as 200,300,400,600,800,1000......8000 refer below screenshot.
Expected Something like below chart
Sample Code used to Draw the chart
<LineChart width={600} height={500} data={curveData} margin={{ top: 50, right: 20, bottom: 50, left: 20 }}>
<XAxis dataKey='frequency' scale={'log'}>
<YAxis type='number' domain={[minYAxisScale, maxYAxisScale]} tickCount={10} minTickGap={50}>
I try to use scale as log/pow. But does not help. Kindly provide suggestion to achieve this.
Beta Was this translation helpful? Give feedback.
All reactions