I have been trying to find a way to add axis ticks and axis label on a PDF. Thus far I have only found a way to add the axis label. Could someone help me?
I am trying to go from this:
to axis ticks, looking like this:
The code I am using right now:
\begin{figure}[htb]
\begin{minipage}{0.4\textwidth}
\begin{tikzpicture}
\node (img) {\includegraphics[scale=0.225]{example-image}};
\node[below=of img, node distance=0cm, yshift=1cm,font=\color{red}] {x-axis};
\node[left=of img, node distance=0cm, rotate=90, anchor=center,yshift=-0.7cm,font=\color{red}] {y-axis};
\end{tikzpicture}
\end{minipage}%
\begin{minipage}{0.4\textwidth}
\begin{tikzpicture}
\node (img) {\includegraphics[scale=0.225]{aa12.pdf}};
\node[below=of img, node distance=0cm, yshift=1cm,font=\color{black}] {x-axis};
\node[left=of img, node distance=0cm, rotate=90, anchor=center,yshift=-0.7cm,font=\color{red}] {y-axis};
\end{tikzpicture}
\end{minipage}%
\end{figure}
pgfplots
package to print the plot directly in latex? Otherwise, I can only suggest to make the plot with the axis in a separate program because you'll never get the scaling correct if you only attach an axis separately to a plot.