Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Why gnuplot plots circles of different radius when I use "with circles"?

1,014 views
Skip to first unread message

Roman Gorbunov

unread,
Sep 16, 2010, 10:26:05 AM9/16/10
to
Hi All,

I am trying to use "with circles" to plot data as circles. And I want
to do it in polar coordinates. So, I have this code:

set size square
set angles degrees
set polar
set grid polar
plot "file.dat" u 1:2:(10.0) t "" w circles

In my file.dat I have angle (in degree) in the first column, the
second column contains the distance from the center (I use polar
coordinates). My circles have correct position but they have different
radius? Why.

I thought that the radius is specified as the third column. So, fixed
it ti 10.0 but it does not work.

My "file.dat" has the following content:
0.0 1.0
90.0 2.0
180.0 3.0
270.0 4.0

sfeam

unread,
Sep 16, 2010, 1:00:49 PM9/16/10
to
Roman Gorbunov wrote:

> Hi All,
>
> I am trying to use "with circles" to plot data as circles. And I want
> to do it in polar coordinates.

Quite probably no one ever tested "with circles" in polar coordinate mode.
Please file a bug report.

That said, I honestly don't even know what to expect for a plot
command of the form you show. The documentation says that the circle
radius is always interpreted "in terms of" the horizontal axis, but
what exactly does that mean in polar mode?

Anyhow, although the bug may make this not work either, I suggest that
to clarify the intended circle radius you do it this way:

set style circle radius graph 0.05
plot 'file.dat' u 1:2 w circles

As a work-around, you can save the orthogonalized coordinates to a
file and then replot:

set polar
set table 'temp.dat'


plot 'file.dat' u 1:2

unset table
unset polar
plot 'temp.dat' u 1:2 with circles

0 new messages