nt of Social and Health Services
-Original Message-
From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Alain
Guillet
Sent: Thursday, September 29, 2016 2:42 AM
To: r-help@r-project.org
Subject: Re: [R] using read.csv2()
Hello,
The defaults in read.csv2 are ";" as t
Original Message-
> From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Alain
> Guillet
> Sent: Thursday, September 29, 2016 2:42 AM
> To: r-help@r-project.org
> Subject: Re: [R] using read.csv2()
>
> Hello,
>
> The defaults in read.csv2 are ";"
Hello,
The defaults in read.csv2 are ";" as the separator and "," as the
decimal symbol. It seems that the file you import is not a true csv
since it mixes up two norms.
You can solve your problem in defining the dec option equals to ".":
read.csv2("test.csv",dec=".")->don
Alain
On 29/09/
> On 29 Sep 2016, at 11:40 , Duncan Murdoch wrote:
>
>
> It's a "factor". read.csv2() defaults to a decimal separator of "," rather
> than ".", so the last column doesn't look like numbers, and they're being
> read as character strings, and then automatically converted to a factor.
> Readin
On 29/09/2016 4:59 AM, Voirin Pascale wrote:
Hello,
I have a problem with the variable type defined by reading a csv file with
read.csv2.
Here is a test file saved as < test.csv > :
var1;var2;var3
TI;1995;4.5
VD;1990;4.8
FR;1994;3.9
VS;1993;5.1
FR;1995;4.7
FR;1992;5.8
That I read in R with :
Voirin Pascale writes:
> Hello,
>
> I have a problem with the variable type defined by reading a csv file with
> read.csv2.
>
> Here is a test file saved as < test.csv > :
> var1;var2;var3
> TI;1995;4.5
> VD;1990;4.8
> FR;1994;3.9
> VS;1993;5.1
> FR;1995;4.7
> FR;1992;5.8
>
> That I read in R w
Hello,
I have a problem with the variable type defined by reading a csv file with
read.csv2.
Here is a test file saved as < test.csv > :
var1;var2;var3
TI;1995;4.5
VD;1990;4.8
FR;1994;3.9
VS;1993;5.1
FR;1995;4.7
FR;1992;5.8
That I read in R with :
read.csv2("test.csv")->don;don
don$var3
## [1]
7 matches
Mail list logo