Code: Select all
\pspicture(-5,5)(5,5)
\psaxes[linecolor=gray]{<->}(0,0)(-4,-5)(5,5)
\psplot[plotstyle=curve,linewidth=2pt,arrows=<->,linecolor=red]{-3.5}{-1}{4 x x mul mul 18 x mul add 17 add}
\endpspicture
\vspace{1in}
Nick
Code: Select all
\pspicture(-5,5)(5,5)
\psaxes[linecolor=gray]{<->}(0,0)(-4,-5)(5,5)
\psplot[plotstyle=curve,linewidth=2pt,arrows=<->,linecolor=red]{-3.5}{-1}{4 x x mul mul 18 x mul add 17 add}
\endpspicture
\vspace{1in}
NEW: TikZ book now 40% off at Amazon.com for a short time.
next time provide _full_ working examples, not only code fragments ...coachbennett1981 wrote:I have a question about the following code:
I want to change the scale so I can fit this graph into beamer presentation, I wanted to have the range be from -4 to -1. The output at x=-4 is 9. How can I change the graph so the axis will go that high and not take up so much room on the page? I have changed Dy=2, but that just spaces out the values for y. Any suggestions?
Code: Select all
\documentclass{beamer}
\usepackage{pst-plot}
\begin{document}
\begin{frame}{Title}{subtitle}
\begin{center}
\resizebox{0.7\linewidth}{!}{%
\pspicture(-5,-5)(5,5)
\psaxes[linecolor=gray]{<->}(0,0)(-4,-5)(5,5)
\psplot[plotstyle=curve,linewidth=2pt,arrows=<->,
linecolor=red]{-3.5}{-1}{4 x x mul mul 18 x mul add 17 add}
\endpspicture}
\end{center}
\end{frame}
\end{document}
coachbennett1981 wrote:I see how you resized the figure, but I am wondering how to change the yaxis so that if I wanted to go out further (to 9) I can, I have changed the Dy=2, etc, but it does not work..
Code: Select all
while (true) {
_complete_ example
}
NEW: TikZ book now 40% off at Amazon.com for a short time.