Specific frameticks in ListLogPlot

rp = 2*10^3;
ro = 1.88*10^8;
h[p_] := p (rp/ro)^2;
listh = Table[{p, h[p]}, {p, 1, 100000}];
ListLogPlot[listh, PlotTheme -> "Detailed", LabelStyle -> Black, FrameStyle -> {Black, 10},PlotRange -> All]

This code plots the graph seen below I just wanted to change the frameticks in the horizontal axis like 2x10^4, 4x10^4, 6x10^4, 8x10^4, 1x10^5. How is this possible?

• Related: (5369) Mar 8 '20 at 16:03

It's possible to define and use a custom ticks function as follows:

ticksfn =
{#, ScientificForm[N@#, NumberPoint -> ""]} & /@
FindDivisions[{#, #2}, 6] &;

rp = 2*10^3;
ro = 1.88*10^8;
h[p_] := p (rp/ro)^2;
listh = Table[{p, h[p]}, {p, 1, 100000}];
plot = ListLogPlot[listh, PlotTheme -> "Detailed", LabelStyle -> Black,
FrameStyle -> {Black, 10}, PlotRange -> All,
FrameTicks -> {{Automatic, None}, {ticksfn, None}}] More complete with the sub-ticks, but possibly version specific (here for v10.1):

ticksfn =
Map[Replace[{v_, n_} :> {v, ScientificForm[N@v, NumberPoint -> ""]}]]@*
ChartingFindTicks[# &, # &]; Try this:

[rp = 2*10^3;
ro = 1.88*10^8;
h[p_] := p (rp/ro)^2;
listh = Table[{p, h[p]}, {p, 1, 100000}];
ListLogPlot[listh, PlotTheme -> "Detailed", LabelStyle -> Black,
FrameStyle -> {Black, 10}, PlotRange -> All,
FrameTicks -> {{Automatic,
None}, {{{20000,
Style["2×\!$$\*SuperscriptBox[\(10$$, $$4$$]\)", 12,
Black]}, {40000,
Style["4×\!$$\*SuperscriptBox[\(10$$, $$4$$]\)", 12,
Black]}, {60000,
Style["6×\!$$\*SuperscriptBox[\(10$$, $$4$$]\)", 12,
Black]}, {80000,
Style["8×\!$$\*SuperscriptBox[\(10$$, $$4$$]\)", 12,
Black]}}, None}}]`] Have fun!

• Thank you very much. Feb 12 '20 at 7:57