noticed it.
It may indeed make sense to more fully specify package::function notation in
anything you let others use as they may indeed load more packages …
From: John C Frain
Sent: Thursday, August 26, 2021 3:17 PM
To: Kai Yang
Cc: r-help@r-project.org; Avi Gross
Subject: Re: [R
indeed load more packages …
From: John C Frain
Sent: Thursday, August 26, 2021 3:17 PM
To: Kai Yang
Cc: r-help@r-project.org; Avi Gross
Subject: Re: [R] ggplot error of "`data` must be a data frame, or other object
coercible by `fortify()`, not an S3 object with class rxlsx"
Hello,
Package 'officer' has a function 'read_xlsx', so when you attach those
packages in that order, it returns 'read_xlsx' from package 'officer'
instead of 'readxl'. To avoid the confusion, instead of
eth <- read_xlsx("c:/temp/eth.xlsx")
try
eth <- readxl::read_xlsx("c:/temp/eth.xlsx")
whi
The packages "officer" and "readxl" both contain functions named
"read_xlsx". It looks like you want the one from readxl so refer to it as
readxl::read_xlsx instead of just read_xlsx.
-Bill
On Thu, Aug 26, 2021 at 12:03 PM Kai Yang via R-help
wrote:
> Hi all,
> I found something, but I don't
officer redefines the read_xlsx command. You should have got a message to
that effect when you loaded the officer package. You can use the version
from the readxl package with
readxl::read_xlsx() command.
John C Frain
3 Aranleigh Park
Rathfarnham
Dublin 14
Ireland
www.tcd.ie/Economics/staff/fr
Hi all,
I found something, but I don't know why it happen.
when I submitted the following code, the Eth is data frame. I can see 14 obs.
of 2 variables
library(readxl)
library(ggplot2)
eth <- read_xlsx("c:/temp/eth.xlsx")
but when I add more package (see below,) the Eth is "List of 1"
library(r
Hi All,
1. the eth is a data frame (not sure that based on error message?) that I load
it from excel file. Here is the code: eth <- read_xlsx("c:/temp/eth.xlsx")
2. I try to use the code to convert eth into eth2, but I got error message:
> eth2 <- data.frame(eth)
Error in as.data.frame.default(x[
Kai,
The answer is fairly probable to find if you examine your variable "eth" as
that is the only time you are being asked to provide the argument as in
"ggplot(data=eth, ..) ...)
As the message states, it expects that argument to be a data frame or something
it can change into a data.frame.
The class of 'eth' must be incorrect. You could try 'as.data.frame' or
possibly 'as.list' to convert 'eth' to an acceptable form.
On Thu, Aug 26, 2021, 11:53 Kai Yang via R-help
wrote:
> Hello List,
> I got an error message when I submit the code below
> ggplot(eth, aes(ymax=ymax, ymin=ymin, xma
eth is not a dataframe but of the class rxlsx. You'll need to convert eth
into a dataframe.
ir. Thierry Onkelinx
Statisticus / Statistician
Vlaamse Overheid / Government of Flanders
INSTITUUT VOOR NATUUR- EN BOSONDERZOEK / RESEARCH INSTITUTE FOR NATURE AND
FOREST
Team Biometrie & Kwaliteitszorg /
I get the same result as Eric withR version 3.4.2 (2017-09-28)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 17.04
It looks like you have "tidyverse" loaded so I tried it with just ggplot2
loaded and with tidyverse loaded.
On Wednesday, November 8, 2017, 4:16:14 AM EST, Eri
Thanks,
I think, I found the problem. It seems to related locale setting.
If I start with 'LANG=C R' everything's good.
--
Zeki Çatav
zekicatav.com
On Nov 8, 2017 1:56 PM, "John Kane" wrote:
I get the same result as Eric with
R version 3.4.2 (2017-09-28)
Platform: x86_64-pc-linux-gnu (64-bit)
I was not able to reproduce this problem. I tried two environments
1. Ubuntu 14.04.5 LTS, R version 3.4.2 (same R version as yours)
2. Windows 10, same R version
On Wed, Nov 8, 2017 at 9:50 AM, Zeki ÇATAV wrote:
> Hello,
> I've an error recently.
>
> ggplot(data = mtcars, aes(x= wt, y= mpg)) +
13 matches
Mail list logo