Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.graphics.apps.gnuplot > #2659

Re: set linetype cycle n

From Ethan A Merritt <sfeam@users.sourceforge.net>
Newsgroups comp.graphics.apps.gnuplot
Subject Re: set linetype cycle n
Date 2014-12-09 10:00 -0800
Organization gnuplot development
Message-ID <m67dbp$q5c$1@dont-email.me> (permalink)
References <547f042f$0$2879$e4fe514c@news2.news.xs4all.nl> <m5rbh5$qad$1@dont-email.me> <5486e194$0$2904$e4fe514c@news2.news.xs4all.nl>

Show all headers | View raw


Alex van der Spek wrote:

> On Thu, 04 Dec 2014 20:15:50 -0800, Ethan A Merritt wrote:
> 
>> Alex van der Spek wrote:
>> 
>>> It appears as if at least in the CVS version the cycle of linetypes is
>>> limited to (hardcoded as) 8.
>> 
>>    Not correct.
>>    Is there something in the docs or demos that gives that impression?
>> 
>>> Would be nice to be able to set the cycle to an integer of the user's
>>> choice.
>>> 
>>> Is that possible?
>> 
>>    set linetype cycle N
>> 
>> Of course if you choose a large value of N you have to first define at
>> least that many linetypes for it to make sense.
>> 
>> 
>>> Regards,
>>> Alex van der Spek
> 
> 
> The 5.1 PDF docs do not refer to any other possible choice.
> Page 133 in the PDF only shows 8.
> The full syntax of the command I could not find.
> 
> 
> I was interested in setting N to values smaller than 8, say 4 or 3.
> Would make it easy to plot repeat experimental data with the same
> linetype, save for the dashtype.

Here is a full description, which seems overly complex to put in the
help files.

Consider the commands
	set linetype cycle N
	plot $FOO with lines linetype 25

If a "linetype 25" has previously been defined, this is what the 
program will use.   If there is no previously defined linetype 25,
then the program will instead use line properties from a linetype
between 1 and N:
	newlinetype = (25-1) % N + 1

So if N=5 then linetype 25 will use the color, width, etc of linetype 5.
But if N=2 or N=3 or N=4 then linetype 25 will use the properties of 
linetype 1 because 2,3,4 are factors of 24 and therefore 25 is the
first member of a new cycle of N.

	Ethan

Back to comp.graphics.apps.gnuplot | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

set linetype cycle n Alex van der Spek <zdoor@xs4all.nl> - 2014-12-03 12:38 +0000
  Re: set linetype cycle n Ethan A Merritt <EAMerritt@gmail.com> - 2014-12-04 20:15 -0800
    Re: set linetype cycle n Alex van der Spek <zdoor@xs4all.nl> - 2014-12-09 11:48 +0000
      Re: set linetype cycle n Ethan A Merritt <sfeam@users.sourceforge.net> - 2014-12-09 10:00 -0800
        Re: set linetype cycle n Alex van der Spek <zdoor@xs4all.nl> - 2014-12-10 16:35 +0000
          Re: set linetype cycle n Ethan A Merritt <EAMerritt@gmail.com> - 2014-12-10 08:41 -0800
            Re: set linetype cycle n Alex van der Spek <zdoor@xs4all.nl> - 2014-12-12 10:06 +0000

csiph-web