[R] error message; ylim + log="y"
Peter Alspach
Peter.Alspach at plantandfood.co.nz
Wed Nov 18 23:57:26 CET 2009
Tena koe Martin
This is what I get (it is unclear to me why you don't tell use
specifically what you get):
plot(1,1, xlim=c(1,10), ylim=c(0,10000), log="y", type='n')
Warning message:
In plot.window(...) : nonfinite axis limits [GScale(-inf,4,2, .); log=1]
plot(1,1, xlim=c(1,10), ylim=c(1,10000), log="y", type='n')
Not unreasonably, R has difficulty determining the y axis limits when
you tell it the minimum is log(0).
HTH ....
Peter Alspach
> -----Original Message-----
> From: r-help-bounces at r-project.org
> [mailto:r-help-bounces at r-project.org] On Behalf Of Martin Batholdy
> Sent: Thursday, 19 November 2009 11:32 a.m.
> To: r help
> Subject: Re: [R] error message; ylim + log="y"
>
> > You have no data to plot. What were you expecting it to do?
>
>
> Well, I get the same error messages when I use real data.
> So it has to do with the ylim-values specified.
> When I get rid of the ylim argument definition it does work.
>
>
> But why?
> I don't understand why R can't plot a logarithmic y-axis from
> 1 to 10.000.
> It doesn't need data for that, does it?
>
>
>
>
> Am 18.11.2009 um 23:19 schrieb jim holtman:
>
> > like this?
> >
> >> plot(c(),c(), xlim=c(1,10), ylim=c(0,10000), log="y")
> > Error in axis(side = side, at = at, labels = labels, ...) :
> > CreateAtVector [log-axis()]: axp[0] = 0 < 0!
> > In addition: Warning messages:
> > 1: In is.na(y) : is.na() applied to non-(list or vector) of
> type 'NULL'
> > 2: In plot.window(...) :
> > nonfinite axis limits [GScale(-inf,4,2, .); log=1]
> > 3: In axis(side = side, at = at, labels = labels, ...) :
> > CreateAtVector "log"(from axis()): axp[0] = 0 !
> >
> >
> > You have no data to plot. What were you expecting it to
> do? When you
> > say "lot of error messages", please include them and also
> follow the
> > posting guide.
> >
> > On Wed, Nov 18, 2009 at 4:52 PM, Martin Batholdy
> > <batholdy at googlemail.com> wrote:
> >> Hi,
> >>
> >>
> >> I get a lot of error messages with this command, but I don't
> >> understand why;
> >>
> >> plot(c(),c(), xlim=c(1,10), ylim=c(0,10000), log="y")
> >>
> >>
> >> thanks for any help!
> >> [[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.
> >>
> >
> >
> >
> > --
> > Jim Holtman
> > Cincinnati, OH
> > +1 513 646 9390
> >
> > What is the problem that you are trying to solve?
>
> ______________________________________________
> 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.
>
More information about the R-help
mailing list