An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20130112/b47963ef/attachment-0001.pl>
Drawing a dotted circle.
13 messages · arun, Jose Iparraguirre, Ben Bolker +6 more
HI Ved, I was able to get the dotted circle using the same command.? I am using R 2.15 on Ubuntu 12.04. A.K.? ----- Original Message ----- From: Ved P. Sharma <vedsharma at gmail.com> To: r-help at r-project.org Cc: Sent: Saturday, January 12, 2013 2:43 AM Subject: [R] Drawing a dotted circle. Hi, I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I making a mistake? Ved ??? [[alternative HTML version deleted]] ______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Ved P. Sharma <vedsharma <at> gmail.com> writes:
I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I making a mistake?
Works for me (although it's a dashed line; lty=3 gives a dotted line) on Ubuntu 10.04, R-devel. Results of sessionInfo() please?
Hi Arun, Thanks for your reply. I am running R 2.15.2 (32-bit) on Windows 7. Please take a look at the attached image of the circle, which does not look dotted to me. I also tried it on RStudio and it gives the same result, i.e. solid line. Ved
On Sat, Jan 12, 2013 at 11:43 AM, arun <smartpink111 at yahoo.com> wrote:
HI Ved,
I was able to get the dotted circle using the same command. I am using R 2.15 on Ubuntu 12.04.
A.K.
----- Original Message -----
From: Ved P. Sharma <vedsharma at gmail.com>
To: r-help at r-project.org
Cc:
Sent: Saturday, January 12, 2013 2:43 AM
Subject: [R] Drawing a dotted circle.
Hi,
I am trying to draw a dotted circle by using symbols command:
symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2)
But it gives me a solid line. I was just wondering whether am I making a
mistake?
Ved
[[alternative HTML version deleted]]
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Don't know, but you can use the function draw.circle in the plotrix package. Hope this helps, Jose
From: r-help-bounces at r-project.org [r-help-bounces at r-project.org] On Behalf Of Ved P. Sharma [vedsharma at gmail.com]
Sent: 12 January 2013 07:43
To: r-help at r-project.org
Subject: [R] Drawing a dotted circle.
Sent: 12 January 2013 07:43
To: r-help at r-project.org
Subject: [R] Drawing a dotted circle.
Hi,
I am trying to draw a dotted circle by using symbols command:
symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2)
But it gives me a solid line. I was just wondering whether am I making a
mistake?
Ved
[[alternative HTML version deleted]]
______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Wrap Up and Run 10k is back!
Also, new for 2013 ? 2km intergenerational walks at selected venues. So recruit a buddy, dust off the trainers and beat the winter blues by
signing up now:
http://www.ageuk.org.uk/10k
Milton Keynes | Oxford | Sheffield | Crystal Palace | Exeter | Harewood House, Leeds |
Tatton Park, Cheshire | Southampton | Coventry
Age UK Improving later life
http://www.ageuk.org.uk
-------------------------------
Age UK is a registered charity and company limited by guarantee, (registered charity number 1128267, registered company number 6825798).
Registered office: Tavis House, 1-6 Tavistock Square, London WC1H 9NA.
For the purposes of promoting Age UK Insurance, Age UK is an Appointed Representative of Age UK Enterprises Limited, Age UK is an Introducer
Appointed Representative of JLT Benefit Solutions Limited and Simplyhealth Access for the purposes of introducing potential annuity and health
cash plans customers respectively. Age UK Enterprises Limited, JLT Benefit Solutions Limited and Simplyhealth Access are all authorised and
regulated by the Financial Services Authority.
------------------------------
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are
addressed. If you receive a message in error, please advise the sender and delete immediately.
Except where this email is sent in the usual course of our business, any opinions expressed in this email are those of the author and do not
necessarily reflect the opinions of Age UK or its subsidiaries and associated companies. Age UK monitors all e-mail transmissions passing
through its network and may block or modify mails which are deemed to be unsuitable.
Age Concern England (charity number 261794) and Help the Aged (charity number 272786) and their trading and other associated companies merged
on 1st April 2009. Together they have formed the Age UK Group, dedicated to improving the lives of people in later life. The three national
Age Concerns in Scotland, Northern Ireland and Wales have also merged with Help the Aged in these nations to form three registered charities:
Age Scotland, Age NI, Age Cymru.
Hello, Checks ok on Ubuntu 12.04 but not on Windows 7, where it plots a solid line circle. symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) sessionInfo() R version 2.15.2 (2012-10-26) Platform: x86_64-w64-mingw32/x64 (64-bit) locale: [1] LC_COLLATE=Portuguese_Portugal.1252 LC_CTYPE=Portuguese_Portugal.1252 [3] LC_MONETARY=Portuguese_Portugal.1252 LC_NUMERIC=C [5] LC_TIME=Portuguese_Portugal.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base loaded via a namespace (and not attached): [1] tools_2.15.2 Hope this helps, Rui Barradas Em 12-01-2013 17:02, Ben Bolker escreveu:
Ved P. Sharma <vedsharma <at> gmail.com> writes:
I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I making a mistake?
Works for me (although it's a dashed line; lty=3 gives a dotted line) on Ubuntu 10.04, R-devel. Results of sessionInfo() please?
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
A wild guess which I can't check right now, but: is there something
funny/different with the Windows graphics driver that draws the result
of a dashed line based on many closely spaced points as a solid line?
i.e., it draws a dash for the beginning of every segment within the
line, even if they are close together, resulting in overlapping dashes
-> a solid line? Don't have time to dig into
.External.graphics(C_symbols, x, y, type, data,
inches, bg, fg, ...)
right now ...
On 13-01-12 01:41 PM, Rui Barradas wrote:
Hello, Checks ok on Ubuntu 12.04 but not on Windows 7, where it plots a solid line circle. symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) sessionInfo() R version 2.15.2 (2012-10-26) Platform: x86_64-w64-mingw32/x64 (64-bit) locale: [1] LC_COLLATE=Portuguese_Portugal.1252 LC_CTYPE=Portuguese_Portugal.1252 [3] LC_MONETARY=Portuguese_Portugal.1252 LC_NUMERIC=C [5] LC_TIME=Portuguese_Portugal.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base loaded via a namespace (and not attached): [1] tools_2.15.2 Hope this helps, Rui Barradas Em 12-01-2013 17:02, Ben Bolker escreveu:
Ved P. Sharma <vedsharma <at> gmail.com> writes:
I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I making a mistake?
Works for me (although it's a dashed line; lty=3 gives a dotted line) on Ubuntu 10.04, R-devel. Results of sessionInfo() please?
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Hello,
In Windows it's
.Internal(symbols(x, y, type, data, inches, bg, fg, ...))
And this is what I've found:
file r-2.15.2\src\main\graphics.c
function GSymbol
/*
* Force line type LTY_SOLID
* i.e., current par(lty) is ignored when drawing symbols
*/
gc.lty = LTY_SOLID;
So, the op is out of luck, lty solid is hard-coded in the C source.
Maybe plotrix::draw.circle, like Jose suggested.
Rui Barradas
Em 12-01-2013 18:53, Ben Bolker escreveu:
A wild guess which I can't check right now, but: is there something
funny/different with the Windows graphics driver that draws the result
of a dashed line based on many closely spaced points as a solid line?
i.e., it draws a dash for the beginning of every segment within the
line, even if they are close together, resulting in overlapping dashes
-> a solid line? Don't have time to dig into
.External.graphics(C_symbols, x, y, type, data,
inches, bg, fg, ...)
right now ...
On 13-01-12 01:41 PM, Rui Barradas wrote:
Hello, Checks ok on Ubuntu 12.04 but not on Windows 7, where it plots a solid line circle. symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) sessionInfo() R version 2.15.2 (2012-10-26) Platform: x86_64-w64-mingw32/x64 (64-bit) locale: [1] LC_COLLATE=Portuguese_Portugal.1252 LC_CTYPE=Portuguese_Portugal.1252 [3] LC_MONETARY=Portuguese_Portugal.1252 LC_NUMERIC=C [5] LC_TIME=Portuguese_Portugal.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base loaded via a namespace (and not attached): [1] tools_2.15.2 Hope this helps, Rui Barradas Em 12-01-2013 17:02, Ben Bolker escreveu:
Ved P. Sharma <vedsharma <at> gmail.com> writes:
I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I making a mistake?
Works for me (although it's a dashed line; lty=3 gives a dotted line) on Ubuntu 10.04, R-devel. Results of sessionInfo() please?
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
You can get a dashed line if you plot to pdf() or svg(), but not any of the bitmap devices. The ellipse() function in the car package will work, but you have to set up the plot first: library(car) plot(c(-1.1, 1.1), c(-1.1, 1.1), type="n", asp=1) ellipse(c(0, 0), matrix(c(1,0,0,1), 2), 1, lty=2, co="gray", center.pch="") ---------------------------------------------- David L Carlson Associate Professor of Anthropology Texas A&M University College Station, TX 77843-4352
-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
project.org] On Behalf Of Rui Barradas
Sent: Saturday, January 12, 2013 1:21 PM
To: Ben Bolker
Cc: r-help at stat.math.ethz.ch; vedsharma at gmail.com
Subject: Re: [R] Drawing a dotted circle.
Hello,
In Windows it's
.Internal(symbols(x, y, type, data, inches, bg, fg, ...))
And this is what I've found:
file r-2.15.2\src\main\graphics.c
function GSymbol
/*
* Force line type LTY_SOLID
* i.e., current par(lty) is ignored when drawing symbols
*/
gc.lty = LTY_SOLID;
So, the op is out of luck, lty solid is hard-coded in the C source.
Maybe plotrix::draw.circle, like Jose suggested.
Rui Barradas
Em 12-01-2013 18:53, Ben Bolker escreveu:
A wild guess which I can't check right now, but: is there
something
funny/different with the Windows graphics driver that draws the
result
of a dashed line based on many closely spaced points as a solid line? i.e., it draws a dash for the beginning of every segment within the line, even if they are close together, resulting in overlapping
dashes
-> a solid line? Don't have time to dig into
.External.graphics(C_symbols, x, y, type, data,
inches, bg, fg, ...)
right now ...
On 13-01-12 01:41 PM, Rui Barradas wrote:
Hello, Checks ok on Ubuntu 12.04 but not on Windows 7, where it plots a
solid
line circle. symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) sessionInfo() R version 2.15.2 (2012-10-26) Platform: x86_64-w64-mingw32/x64 (64-bit) locale: [1] LC_COLLATE=Portuguese_Portugal.1252
LC_CTYPE=Portuguese_Portugal.1252
[3] LC_MONETARY=Portuguese_Portugal.1252 LC_NUMERIC=C [5] LC_TIME=Portuguese_Portugal.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base loaded via a namespace (and not attached): [1] tools_2.15.2 Hope this helps, Rui Barradas Em 12-01-2013 17:02, Ben Bolker escreveu:
Ved P. Sharma <vedsharma <at> gmail.com> writes:
I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I
making a
mistake?
Works for me (although it's a dashed line; lty=3 gives a dotted line) on Ubuntu 10.04, R-devel. Results of sessionInfo() please?
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting- guide.html and provide commented, minimal, self-contained, reproducible code.
Thanks everyone for suggesting the alternative draw.circle. Ved On Sat, Jan 12, 2013 at 12:50 PM, Jose Iparraguirre
<Jose.Iparraguirre at ageuk.org.uk> wrote:
Don't know, but you can use the function draw.circle in the plotrix package. Hope this helps, Jose
________________________________________
From: r-help-bounces at r-project.org [r-help-bounces at r-project.org] On Behalf Of Ved P. Sharma [vedsharma at gmail.com]
Sent: 12 January 2013 07:43
To: r-help at r-project.org
Subject: [R] Drawing a dotted circle.
Hi,
I am trying to draw a dotted circle by using symbols command:
symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2)
But it gives me a solid line. I was just wondering whether am I making a
mistake?
Ved
[[alternative HTML version deleted]]
______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Wrap Up and Run 10k is back!
Also, new for 2013 ? 2km intergenerational walks at selected venues. So recruit a buddy, dust off the trainers and beat the winter blues by
signing up now:
http://www.ageuk.org.uk/10k
Milton Keynes | Oxford | Sheffield | Crystal Palace | Exeter | Harewood House, Leeds |
Tatton Park, Cheshire | Southampton | Coventry
Age UK Improving later life
http://www.ageuk.org.uk
-------------------------------
Age UK is a registered charity and company limited by guarantee, (registered charity number 1128267, registered company number 6825798).
Registered office: Tavis House, 1-6 Tavistock Square, London WC1H 9NA.
For the purposes of promoting Age UK Insurance, Age UK is an Appointed Representative of Age UK Enterprises Limited, Age UK is an Introducer
Appointed Representative of JLT Benefit Solutions Limited and Simplyhealth Access for the purposes of introducing potential annuity and health
cash plans customers respectively. Age UK Enterprises Limited, JLT Benefit Solutions Limited and Simplyhealth Access are all authorised and
regulated by the Financial Services Authority.
------------------------------
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are
addressed. If you receive a message in error, please advise the sender and delete immediately.
Except where this email is sent in the usual course of our business, any opinions expressed in this email are those of the author and do not
necessarily reflect the opinions of Age UK or its subsidiaries and associated companies. Age UK monitors all e-mail transmissions passing
through its network and may block or modify mails which are deemed to be unsuitable.
Age Concern England (charity number 261794) and Help the Aged (charity number 272786) and their trading and other associated companies merged
on 1st April 2009. Together they have formed the Age UK Group, dedicated to improving the lives of people in later life. The three national
Age Concerns in Scotland, Northern Ireland and Wales have also merged with Help the Aged in these nations to form three registered charities:
Age Scotland, Age NI, Age Cymru.
On 01/12/2013 06:43 PM, Ved P. Sharma wrote:
Hi, I am trying to draw a dotted circle by using symbols command: symbols(0, 0, circles = 1, inches = FALSE, fg = 'gray', lty=2) But it gives me a solid line. I was just wondering whether am I making a mistake?
Hi Ved, You can draw circles on a plot using the draw.circle (plotrix) function. If the problem is the method of drawing broken lines as suggested by Ben Bolker, you may be able to get broken lines on Windows by using smaller values in the "nv" argument. By decreasing the number of line segments used to draw the circle, the breaks should appear. Jim
An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20130113/fd2afe1a/attachment-0001.pl>
2 days later
An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20130115/0426fd85/attachment.pl>