How can I change the number point from .
to ,
in CustomTicks
?
The Mathematica built-in function
NumberForm[Plot[…],NumberPoint -> ","]
doesn't work any more, if you use e.g. LinTicks
.
Mathematica Stack Exchange is a question and answer site for users of Wolfram Mathematica. It only takes a minute to sign up.
Sign up to join this communityHow can I change the number point from .
to ,
in CustomTicks
?
The Mathematica built-in function
NumberForm[Plot[…],NumberPoint -> ","]
doesn't work any more, if you use e.g. LinTicks
.
Update
Here is a better way. FixedPointForm
is used to format the tick numbers. Its default options include NumberPoint -> "."
:
Options[FixedPointForm]
(* {NumberSigns -> {"-", ""}, NumberPoint -> ".", SignPadding -> False, Debug -> False} *)
Reset the NumberPoint
option as desired:
SetOptions[FixedPointForm, NumberPoint -> ","];
Plot[E^x Sin[10 x], {x, -1, 1}, Ticks -> LinTicks]
Original
The question, CustomTicks and small ranges, shows one can pass a formatting function to LinTicks
:
Plot[E^x Sin[10 x], {x, -1, 1},
Ticks ->
(LinTicks[##, TickLabelFunction -> (NumberForm[#, {2, 1}, NumberPoint -> ","] &)] &)]
[A weakness in the original solution is having to set the number form explicitly instead of automatically.]
Unless the number point is explicit in this tick package can't you just use Style
to override the global setting? e.g
and
Style[
Plot[E^x Sin[10 x], {x, -1, 1}],
NumberPoint -> "CC"]
NumberPoint
is option for Style
. But since it is you can also use BaseStyle -> {NumberPoint -> ","}
$\endgroup$
– Kuba♦
Oct 6 '13 at 20:44
Ticks
in ways that are described here or in the related topics that are linked in this question. $\endgroup$ – Kuba♦ Oct 5 '13 at 17:15