I have a ListLinePlot with a logarithmic x-axis. I want the FrameTicks to be in scientific form i.e. 10^n.
The code is as follows:
fRD2ticks = {{Automatic,
Automatic}, {Charting`ScaledTicks[{Log, Exp}],
Charting`ScaledFrameTicks[{Log, Exp}]}};
data = {{0.00216864, 3}, {0.00121986, 4}, {0.000780711, 5}, {0.00054216, 6}, {0.0003984, 7}, {0.000305, 8}, {0.000241, 9}, {0.0001952, 10}, {0.00016138, 11}, {0.00013554,
12}, {0.00011549, 13}, {0.00009959, 14}, {0.00008676, 15}, {0.000048795, 20}, {0.000031229, 25}, {0.00002169,
30}, {0.00001594, 35}, {0.000012199, 40}, {0.00001, 44.179}};
ListLinePlot[data,
Frame -> True,
InterpolationOrder -> 2,
FrameTicks -> fRD2ticks,
FrameLabel -> {"Target Radius (m)", "Initial SMA (au)"},
LabelStyle -> {FontFamily -> "Baskerville", FontSize -> 12, Bold},
FrameStyle -> Directive[Thick, Black], ImageSize -> Medium,
PlotRange -> {-2, 46},
ScalingFunctions -> {"Log", None},
PlotRange -> Automatic]
Note that the data the plot uses is imported, hence I can't show an image of the plot.
One method which I tried involved manually defining ticks as:
testticks = Table[{10^i, Superscript[10, i]}, {i, -5, 2}];
and including this in FrameTicks, however this doesn't work.
Any suggestions would be appreciated.
FrameTicks -> fRD2ticksuseFrameTicks -> {{fRD2ticks,fRD2ticks},Automatic}– Ben Izd Mar 09 '21 at 19:42