Re: How do i plot a function?

2009-06-25 Thread Liviu Andronic
On 6/25/09, voidie voidina...@gmail.com wrote:
  i would like to plot a simple function like f(x)=3x^2. I know there

You could also do it with Sweave, but this would require knowledge of R.
Liviu


Re: How do i plot a function?

2009-06-25 Thread Murray Eisenberg
Another possible option is to use PiCTeX, available at CTAN.  With 
LaTeX, you have to load the PiCTeX macros and then insert the code for 
your graph within a \beginpicture...\endpicture environment.  I've used 
this with LaTeX, but never with LyX.


Liviu Andronic wrote:

On 6/25/09, voidie voidina...@gmail.com wrote:

 i would like to plot a simple function like f(x)=3x^2. I know there


You could also do it with Sweave, but this would require knowledge of R.
Liviu



--
Murray Eisenberg mur...@math.umass.edu
Mathematics  Statistics Dept.
Lederle Graduate Research Tower  phone 413 549-1020 (H)
University of Massachusetts413 545-2859 (W)
710 North Pleasant Streetfax   413 545-1801
Amherst, MA 01003-9305


Re: How do i plot a function?

2009-06-25 Thread Phil
   i would like to plot a simple function like
 f(x)=3x^2.  

I found an example I had to make a graph using pstricks.   



  

pstricks_simple_graphing.lyx
Description: application/lyx


Re: How do i plot a function?

2009-06-25 Thread Les Denham
On Thursday 25 June 2009, Murray Eisenberg wrote:
 Another possible option is to use PiCTeX, available at CTAN.  With
 LaTeX, you have to load the PiCTeX macros and then insert the code for
 your graph within a \beginpicture...\endpicture environment.  I've used
 this with LaTeX, but never with LyX.

 Liviu Andronic wrote:
  On 6/25/09, voidie voidina...@gmail.com wrote:
   i would like to plot a simple function like f(x)=3x^2. I know there
 
  You could also do it with Sweave, but this would require knowledge of R.
  Liviu

I would do this using Grace (http://plasma-gate.weizmann.ac.il/Grace/) and 
print the plot to a PDF file.  This can then be included in LyX as a figure. 

Within Grace, the menu sequence is: EditDatasetsEditCreate newBy formula

-- 
Les

~~
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html


Re: How do i plot a function?

2009-06-25 Thread Yago

If you need to plot this function you can use this code:

\psset{yunit=0.5cm,xunit=1cm}
\begin{pspicture*}(-2.5,-2)(2.5,10)
\psaxes[Dy=2]{-}(0,0)(-2.5,-1)(2.5,10)
\psset{linewidth=1.5pt}
\psPolynomial[coeff=0 0 3]{-2.5}{5}
\rput[lb](1.6,4.2){$f(x)$}
\end{pspicture*}

You will need the package pst-func in your preamble. See the documentation.
- Original Message - 
From: voidie voidina...@gmail.com

To: lyx-users@lists.lyx.org
Sent: Thursday, June 25, 2009 2:05 AM
Subject: How do i plot a function?



Hey dudes,

i would like to plot a simple function like f(x)=3x^2. I know there
are 2 ways of doing that. The first is to generate an image with an
external tool like gnuplot and include that image in the document
(Which i don't want to do). I would rather use a latex package so the
plot will be generated by data in have in the document. I have been
told i had to alter the latex preamble but is that possible at all? I
know there is a button to include Tex code but that's all.

Cheers!


Re: How do i plot a function?

2009-06-25 Thread Liviu Andronic
On 6/25/09, voidie voidina...@gmail.com wrote:
  i would like to plot a simple function like f(x)=3x^2. I know there

You could also do it with Sweave, but this would require knowledge of R.
Liviu


Re: How do i plot a function?

2009-06-25 Thread Murray Eisenberg
Another possible option is to use PiCTeX, available at CTAN.  With 
LaTeX, you have to load the PiCTeX macros and then insert the code for 
your graph within a \beginpicture...\endpicture environment.  I've used 
this with LaTeX, but never with LyX.


Liviu Andronic wrote:

On 6/25/09, voidie voidina...@gmail.com wrote:

 i would like to plot a simple function like f(x)=3x^2. I know there


You could also do it with Sweave, but this would require knowledge of R.
Liviu



--
Murray Eisenberg mur...@math.umass.edu
Mathematics  Statistics Dept.
Lederle Graduate Research Tower  phone 413 549-1020 (H)
University of Massachusetts413 545-2859 (W)
710 North Pleasant Streetfax   413 545-1801
Amherst, MA 01003-9305


Re: How do i plot a function?

2009-06-25 Thread Phil
   i would like to plot a simple function like
 f(x)=3x^2.  

I found an example I had to make a graph using pstricks.   



  

pstricks_simple_graphing.lyx
Description: application/lyx


Re: How do i plot a function?

2009-06-25 Thread Les Denham
On Thursday 25 June 2009, Murray Eisenberg wrote:
 Another possible option is to use PiCTeX, available at CTAN.  With
 LaTeX, you have to load the PiCTeX macros and then insert the code for
 your graph within a \beginpicture...\endpicture environment.  I've used
 this with LaTeX, but never with LyX.

 Liviu Andronic wrote:
  On 6/25/09, voidie voidina...@gmail.com wrote:
   i would like to plot a simple function like f(x)=3x^2. I know there
 
  You could also do it with Sweave, but this would require knowledge of R.
  Liviu

I would do this using Grace (http://plasma-gate.weizmann.ac.il/Grace/) and 
print the plot to a PDF file.  This can then be included in LyX as a figure. 

Within Grace, the menu sequence is: EditDatasetsEditCreate newBy formula

-- 
Les

~~
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html


Re: How do i plot a function?

2009-06-25 Thread Yago

If you need to plot this function you can use this code:

\psset{yunit=0.5cm,xunit=1cm}
\begin{pspicture*}(-2.5,-2)(2.5,10)
\psaxes[Dy=2]{-}(0,0)(-2.5,-1)(2.5,10)
\psset{linewidth=1.5pt}
\psPolynomial[coeff=0 0 3]{-2.5}{5}
\rput[lb](1.6,4.2){$f(x)$}
\end{pspicture*}

You will need the package pst-func in your preamble. See the documentation.
- Original Message - 
From: voidie voidina...@gmail.com

To: lyx-users@lists.lyx.org
Sent: Thursday, June 25, 2009 2:05 AM
Subject: How do i plot a function?



Hey dudes,

i would like to plot a simple function like f(x)=3x^2. I know there
are 2 ways of doing that. The first is to generate an image with an
external tool like gnuplot and include that image in the document
(Which i don't want to do). I would rather use a latex package so the
plot will be generated by data in have in the document. I have been
told i had to alter the latex preamble but is that possible at all? I
know there is a button to include Tex code but that's all.

Cheers!


Re: How do i plot a function?

2009-06-25 Thread Liviu Andronic
On 6/25/09, voidie  wrote:
>  i would like to plot a simple function like f(x)=3x^2. I know there
>
You could also do it with Sweave, but this would require knowledge of R.
Liviu


Re: How do i plot a function?

2009-06-25 Thread Murray Eisenberg
Another possible option is to use PiCTeX, available at CTAN.  With 
LaTeX, you have to load the PiCTeX macros and then insert the code for 
your graph within a \beginpicture...\endpicture environment.  I've used 
this with LaTeX, but never with LyX.


Liviu Andronic wrote:

On 6/25/09, voidie  wrote:

 i would like to plot a simple function like f(x)=3x^2. I know there


You could also do it with Sweave, but this would require knowledge of R.
Liviu



--
Murray Eisenberg mur...@math.umass.edu
Mathematics & Statistics Dept.
Lederle Graduate Research Tower  phone 413 549-1020 (H)
University of Massachusetts413 545-2859 (W)
710 North Pleasant Streetfax   413 545-1801
Amherst, MA 01003-9305


Re: How do i plot a function?

2009-06-25 Thread Phil
> >>  i would like to plot a simple function like
> f(x)=3x^2.  

I found an example I had to make a graph using pstricks.   



  

pstricks_simple_graphing.lyx
Description: application/lyx


Re: How do i plot a function?

2009-06-25 Thread Les Denham
On Thursday 25 June 2009, Murray Eisenberg wrote:
> Another possible option is to use PiCTeX, available at CTAN.  With
> LaTeX, you have to load the PiCTeX macros and then insert the code for
> your graph within a \beginpicture...\endpicture environment.  I've used
> this with LaTeX, but never with LyX.
>
> Liviu Andronic wrote:
> > On 6/25/09, voidie  wrote:
> >>  i would like to plot a simple function like f(x)=3x^2. I know there
> >
> > You could also do it with Sweave, but this would require knowledge of R.
> > Liviu

I would do this using Grace (http://plasma-gate.weizmann.ac.il/Grace/) and 
print the plot to a PDF file.  This can then be included in LyX as a figure. 

Within Grace, the menu sequence is: Edit>Datasets>Edit>Create new>By formula

-- 
Les

~~
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html


Re: How do i plot a function?

2009-06-25 Thread Yago

If you need to plot this function you can use this code:

\psset{yunit=0.5cm,xunit=1cm}
\begin{pspicture*}(-2.5,-2)(2.5,10)
\psaxes[Dy=2]{->}(0,0)(-2.5,-1)(2.5,10)
\psset{linewidth=1.5pt}
\psPolynomial[coeff=0 0 3]{-2.5}{5}
\rput[lb](1.6,4.2){$f(x)$}
\end{pspicture*}

You will need the package pst-func in your preamble. See the documentation.
- Original Message - 
From: "voidie" <voidina...@gmail.com>

To: <lyx-users@lists.lyx.org>
Sent: Thursday, June 25, 2009 2:05 AM
Subject: How do i plot a function?



Hey dudes,

i would like to plot a simple function like f(x)=3x^2. I know there
are 2 ways of doing that. The first is to generate an image with an
external tool like gnuplot and include that image in the document
(Which i don't want to do). I would rather use a latex package so the
plot will be generated by data in have in the document. I have been
told i had to alter the latex preamble but is that possible at all? I
know there is a button to include Tex code but that's all.

Cheers!


How do i plot a function?

2009-06-24 Thread voidie
Hey dudes,

i would like to plot a simple function like f(x)=3x^2. I know there
are 2 ways of doing that. The first is to generate an image with an
external tool like gnuplot and include that image in the document
(Which i don't want to do). I would rather use a latex package so the
plot will be generated by data in have in the document. I have been
told i had to alter the latex preamble but is that possible at all? I
know there is a button to include Tex code but that's all.

Cheers!


Re: How do i plot a function?

2009-06-24 Thread Phil

 
 i would like to plot a simple function  

I would try to use pstricks package for this.I have not used it recently 
but I do recall that I generated the data points for my function and then used 
pstricks code in ERT to include the datafile in my LyX doc.




  


Re: How do i plot a function?

2009-06-24 Thread Florian Rubach

Phil schrieb:
i would like to plot a simple function  



I would try to use pstricks package for this.
There also is a package called pgf, which includes tikz. Those two are 
really powerful and do have very nice output (see 
http://www.texample.net/tikz/examples/), but like pstricks, time needs 
to be spend reading manuals.
In short, you need to add \usepackage{tikz} and depending on what 
exactly you want to do some other statements in you document 
settings-Latex preamble. Then add the code you learned reading the 
manual in ERT at the places you want, and everything should be fine.


Regards, Florian


How do i plot a function?

2009-06-24 Thread voidie
Hey dudes,

i would like to plot a simple function like f(x)=3x^2. I know there
are 2 ways of doing that. The first is to generate an image with an
external tool like gnuplot and include that image in the document
(Which i don't want to do). I would rather use a latex package so the
plot will be generated by data in have in the document. I have been
told i had to alter the latex preamble but is that possible at all? I
know there is a button to include Tex code but that's all.

Cheers!


Re: How do i plot a function?

2009-06-24 Thread Phil

 
 i would like to plot a simple function  

I would try to use pstricks package for this.I have not used it recently 
but I do recall that I generated the data points for my function and then used 
pstricks code in ERT to include the datafile in my LyX doc.




  


Re: How do i plot a function?

2009-06-24 Thread Florian Rubach

Phil schrieb:
i would like to plot a simple function  



I would try to use pstricks package for this.
There also is a package called pgf, which includes tikz. Those two are 
really powerful and do have very nice output (see 
http://www.texample.net/tikz/examples/), but like pstricks, time needs 
to be spend reading manuals.
In short, you need to add \usepackage{tikz} and depending on what 
exactly you want to do some other statements in you document 
settings-Latex preamble. Then add the code you learned reading the 
manual in ERT at the places you want, and everything should be fine.


Regards, Florian


How do i plot a function?

2009-06-24 Thread voidie
Hey dudes,

i would like to plot a simple function like f(x)=3x^2. I know there
are 2 ways of doing that. The first is to generate an image with an
external tool like gnuplot and include that image in the document
(Which i don't want to do). I would rather use a latex package so the
plot will be generated by data in have in the document. I have been
told i had to alter the latex preamble but is that possible at all? I
know there is a button to include Tex code but that's all.

Cheers!


Re: How do i plot a function?

2009-06-24 Thread Phil

> 
> i would like to plot a simple function  

I would try to use pstricks package for this.I have not used it recently 
but I do recall that I generated the data points for my function and then used 
pstricks code in ERT to include the datafile in my LyX doc.




  


Re: How do i plot a function?

2009-06-24 Thread Florian Rubach

Phil schrieb:
i would like to plot a simple function  



I would try to use pstricks package for this.
There also is a package called pgf, which includes tikz. Those two are 
really powerful and do have very nice output (see 
http://www.texample.net/tikz/examples/), but like pstricks, time needs 
to be spend reading manuals.
In short, you need to add \usepackage{tikz} and depending on what 
exactly you want to do some other statements in you document 
settings->Latex preamble. Then add the code you learned reading the 
manual in ERT at the places you want, and everything should be fine.


Regards, Florian