我应该如何在 pstricks 中绘制有偏差的轴数字

我应该如何在 pstricks 中绘制有偏差的轴数字

问题就在这里。Pstricks 通常绘制具有给定 Dy/Dx 和 dy/dx 的轴,并且生成的图具有所有相同长度的部分,除以相等距离的刻度。如果我们想要有偏差的起始刻度位置不同于指定的 Dy,该怎么办?
这是一个具有偏差 y 轴刻度起始位置的示例图:

有偏差的 y 轴开始刻度

这是我需要参与的代码:

\documentclass[10pt,a4paper]{article}
\usepackage{pstricks-add}
\usepackage{auto-pst-pdf}
\usepackage{pst-pdf}

\begin{document}
\begin{pspicture}(10,10)
\pscurve[showpoints=false]{}(0.31,0.5)(0.8,1.45)(1.31,2.21)(1.9,2.86)%
(2.58,3.41)(3.45,3.89)(4.29,3.89)(4.38, 3.41)%
(4.19, 2.86)(3.89,2.21)(3.61,1.45)(3.37,0.5)
\psaxes[axesstyle=frame, showorigin=false, ylogBase=10, arrowscale=1.5,%
ticksize = -0.08, Ox=150, xunit=0.78,Dx=50,dx=1,%
Oy = 1, yunit=0.33, Dy=1, dy=5](0,0)(8,15)

\end{pspicture}
\end{document}

答案1

你是指这样的吗?

在此处输入图片描述

\documentclass[10pt,a4paper]{article}
\usepackage{pstricks-add}
\usepackage{auto-pst-pdf}

\begin{document}
\begin{pspicture}(10,10)
\psaxes[axesstyle=frame, showorigin=false, ylogBase=10, arrowscale=1.5,%
ticksize = -0.08, Ox=150, xunit=0.78,Dx=50,dx=1,
Oy=1,yunit=0.33,Dy=1,dy=5](0,0)(8,15)
\pscurve(0.31,0.5)(0.8,1.45)(1.31,2.21)(1.9,2.86)%
  (2.58,3.41)(3.45,3.89)(4.29,3.89)(4.38, 3.41)%
  (4.19, 2.86)(3.89,2.21)(3.61,1.45)(3.37,0.5)
\rput(1,0){%
  \pscurve[linecolor=red](0.31,0.5)(0.8,1.45)(1.31,2.21)(1.9,2.86)%
    (2.58,3.41)(3.45,3.89)(4.29,3.89)(4.38, 3.41)%
    (4.19, 2.86)(3.89,2.21)(3.61,1.45)(3.37,0.5)}
\psline[linecolor=red]{->}(1,0.25)(1,4.75)
\rput*(1,1){\small\red123}
\end{pspicture}
\end{document}

相关内容