Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
On Feb 15, 2010, at 2:29 AM, Johannes Graumann wrote: Rolf Turner wrote: On 15/02/2010, at 9:40 AM, Johannes Graumann wrote SNIP (In response to some advice from David Winsemius): I am quite certain that this is the most elaborately worded version of RTFM I have ever come across. I nominate this as a fortune. (Despite Prof. Winsemius's later protestation that his advice was *not* a version of RTFM.) Uh, oh ... certified notoriety? Joh I thought my name might be known, but didn't realize I was notorious. Honest, I was just trying to help. I thought there might be someone out there who had not (yet) bought the book. Sometimes knowing what might be a useful search term is half the answer. I didn't really understand what I was reading, anyway, and after way too much time yesterday have not succeeded in getting any of the advice in those sections to work to create free x, y or both limits. Sigh. -- David Winsemius, MD (not a Prof. of anything) Heritage Laboratories West Hartford, CT __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
On Feb 14, 2010, at 10:33 AM, Johannes Graumann wrote: Hello, When drawing barcharts, I find it not helpful if ylim[1] != 0 - bars for a quantity of 0, that do not show a length of 0 are quite non-intuitive. I have tried to study library(lattice) panel.barchart but am unable to figure out where ylim is taken care of and how one might fix ylim[1] to 0 for barcharts ... Can anyone point out how to tackle this? Looking at Sarkar's Lattice text in chapter 8 section 3 Limits and Aspect Ratio, it appears from subsection 1 that the prepanel function can used to supply values of xlim and ylim values. From subsection 2 he clarifies that xlim and ylim can also be specified on a per panel basis (and here I am guessing that this would be within a scales argument) when relation=free. At the end of that section he offers two examples using ylim: the first is not plotted but the second uses the prepanel mechanism for Fig 8.1 and that is probably available on the Lattice website. In the same subsection is offered an alternative to specifying an explicit scales$y$limits to be interpreted as ylim values. My hope it that these ideas and references will be of some use in identifying productive places to look for further documentation. -- David Winsemius, MD Heritage Laboratories West Hartford, CT __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
On Sun, Feb 14, 2010 at 7:33 AM, Johannes Graumann johannes_graum...@web.de wrote: Hello, When drawing barcharts, I find it not helpful if ylim[1] != 0 - bars for a quantity of 0, that do not show a length of 0 are quite non-intuitive. I have tried to study library(lattice) panel.barchart but am unable to figure out where ylim is taken care of and how one might fix ylim[1] to 0 for barcharts ... Can anyone point out how to tackle this? Are you sure you are not looking for 'origin=0' (described in ?panel.barchart)? -Deepayan __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
David Winsemius wrote: On Feb 14, 2010, at 10:33 AM, Johannes Graumann wrote: Hello, When drawing barcharts, I find it not helpful if ylim[1] != 0 - bars for a quantity of 0, that do not show a length of 0 are quite non-intuitive. I have tried to study library(lattice) panel.barchart but am unable to figure out where ylim is taken care of and how one might fix ylim[1] to 0 for barcharts ... Can anyone point out how to tackle this? Looking at Sarkar's Lattice text in chapter 8 section 3 Limits and Aspect Ratio, it appears from subsection 1 that the prepanel function can used to supply values of xlim and ylim values. From subsection 2 he clarifies that xlim and ylim can also be specified on a per panel basis (and here I am guessing that this would be within a scales argument) when relation=free. At the end of that section he offers two examples using ylim: the first is not plotted but the second uses the prepanel mechanism for Fig 8.1 and that is probably available on the Lattice website. In the same subsection is offered an alternative to specifying an explicit scales$y$limits to be interpreted as ylim values. My hope it that these ideas and references will be of some use in identifying productive places to look for further documentation. I am quite certain that this is the most elaborately worded version of RTFM I have ever come across. I shall go and do so. Sincerely, Joh __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
Deepayan Sarkar wrote: On Sun, Feb 14, 2010 at 7:33 AM, Johannes Graumann johannes_graum...@web.de wrote: Hello, When drawing barcharts, I find it not helpful if ylim[1] != 0 - bars for a quantity of 0, that do not show a length of 0 are quite non-intuitive. I have tried to study library(lattice) panel.barchart but am unable to figure out where ylim is taken care of and how one might fix ylim[1] to 0 for barcharts ... Can anyone point out how to tackle this? Are you sure you are not looking for 'origin=0' (described in ?panel.barchart)? I sure am - thank you! Following the same path for bwplot I found the embarrassingly simple answer to my earlier question regarding varwidth in ... Sincerely, Joh __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
On Feb 14, 2010, at 3:40 PM, Johannes Graumann wrote: David Winsemius wrote: On Feb 14, 2010, at 10:33 AM, Johannes Graumann wrote: Hello, When drawing barcharts, I find it not helpful if ylim[1] != 0 - bars for a quantity of 0, that do not show a length of 0 are quite non- intuitive. I have tried to study library(lattice) panel.barchart but am unable to figure out where ylim is taken care of and how one might fix ylim[1] to 0 for barcharts ... Can anyone point out how to tackle this? Looking at Sarkar's Lattice text in chapter 8 section 3 Limits and Aspect Ratio, it appears from subsection 1 that the prepanel function can used to supply values of xlim and ylim values. From subsection 2 he clarifies that xlim and ylim can also be specified on a per panel basis (and here I am guessing that this would be within a scales argument) when relation=free. At the end of that section he offers two examples using ylim: the first is not plotted but the second uses the prepanel mechanism for Fig 8.1 and that is probably available on the Lattice website. In the same subsection is offered an alternative to specifying an explicit scales$y$limits to be interpreted as ylim values. My hope it that these ideas and references will be of some use in identifying productive places to look for further documentation. I am quite certain that this is the most elaborately worded version of RTFM I have ever come across. Well, not really, it was a version of ... here's my best untested wild guess from someone who persistently struggles with trying to get panel arguments right. I shall go and do so. Sincerely, Joh -- David Winsemius, MD Heritage Laboratories West Hartford, CT __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
On 15/02/2010, at 9:40 AM, Johannes Graumann wrote SNIP (In response to some advice from David Winsemius): I am quite certain that this is the most elaborately worded version of RTFM I have ever come across. I nominate this as a fortune. (Despite Prof. Winsemius's later protestation that his advice was *not* a version of RTFM.) cheers, Rolf Turner ## Attention:\ This e-mail message is privileged and confid...{{dropped:9}} __ R-help@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.
Re: [R] lattice/ylim: how to fix ylim[1], but have ylim[2] dynamically calculated?
Rolf Turner wrote: On 15/02/2010, at 9:40 AM, Johannes Graumann wrote SNIP (In response to some advice from David Winsemius): I am quite certain that this is the most elaborately worded version of RTFM I have ever come across. I nominate this as a fortune. (Despite Prof. Winsemius's later protestation that his advice was *not* a version of RTFM.) Uh, oh ... certified notoriety? Joh __ R-help@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.