Questions tagged [read.csv]

The command in R to read a data file with a “comma separated values” (csv) format.

The read.csv is a command in R to read a data file with a “comma separated values” (csv) format.

737 questions
0
votes
1 answer

Read csv data file in R

I am using read.table to read a data file. and got the following error: Error in scan(file, what, nmax, sep, dec, quote, skip, nlines, na.strings, : scan() expected 'a real', got 'true' I know that means there's some error in my data…
zjffdu
  • 25,496
  • 45
  • 109
  • 159
-1
votes
1 answer

How does "load_dataset" work, as it is not detecting example files?

I´m learning about the seaborn package in Datacamp and one of the files that include in the documentation is "tips.csv", which belongs to the repository [https://github.com/mwaskom/seaborn-data][1] that I have found in other posts. I´m trying to…
-1
votes
1 answer

I have same problem of directory, i tried to change the directory of session from R studio

error showing in the mardown file error showing in the console Itry try to read this csv file but still getting this error
-1
votes
3 answers

Error when parsing string to double in dart

I am trying to read data from a CSV file using Dart. The code I am using reads the lines from the file and splits them into columns using the split() method. One of the columns contains numeric data in string format, which I need to convert to a…
-1
votes
1 answer

reading .csv file with read_csv() results in only one column

Groenigen, Kees Jan van, Xuan Qi, Craig W. Osenberg, Yiqi Luo, and Bruce A. Hungate. “Faster Decomposition Under Increased Atmospheric CO2 Limits Soil Carbon Storage.” Science 344, no. 6183 (May 2, 2014): 508–9.…
-1
votes
1 answer

how to read data from csv file by using quick sort and display it

Can I know what is the best possible way to solve this issue, as I'm currently new to C++ The result that I expected was something like this id, title, price, date, mileage, fuel_type, transmission, engine_size, doors, colour, body_type, url,…
-1
votes
1 answer

How to use csv with python as an expert?

I'm just getting started on python programming. Here is an example of my CSV file : Name tag. description Cool cool,fun cool ... Cell Cell,phone Cell ... Rang first,third rang ... The print with the CSV module gives me a list of all…
JustMe
  • 9
-1
votes
2 answers

How to extract numbers from between commas on each row is csv file

I need to figure out how to separate 3 values from rows in a CSV file into new lists to later plot onto a graph. I already have separated each row into a list, but I need new lists that categorize each comma-separated value. I already separated each…
-1
votes
2 answers

Accessing List values when having few strings inside a value

So I have the following code: void ReadFromCsv() { using (var reader = new StreamReader(@"d:\test.csv", Encoding.Default)) { List listA = new List(); …
user20622377
-1
votes
1 answer

How to display csv data in tabular form in Flask Python?

I'm making a web app using the Flask framework with python, I want to make the web able to upload csv without saving and displaying data in a table with the template I made, I've added the syntax for uploading and processing the data until it's in a…
nadyaggy
  • 1
  • 3
-1
votes
1 answer

Merge information from two files into one CSV file

For example 1st file contains names and dates separated by colon: john:01.01.2001 mary:06.03.2016 And then 2nd file contains names and cities: john:london mary:new york I need top merge them by names into csv file like…
babygroot
  • 19
  • 6
-1
votes
1 answer

drop alternate columns of csv file using pandas or python

print("cols",cols) for i in range(0, cols,2): print("i",i); dataset.drop(dataset.columns[dataset.iloc[:,i]], axis='1', inplace=True) dataset.head() Here cols is total number of columns in csv file( i am reading from my system). Columns…
auriX007
  • 13
  • 1
-1
votes
1 answer

How do I read a csv File with pandas that has multiple values in one column?

I have a csv file that looks like this: timestamp (int), array(value1,value2,...), identifier (string) The arrays with the values inside are exactly written like this: List(value1, value2, value3) where the values can be written in the…
-1
votes
2 answers

Remove additional commas from csv file using Python Pandas

I've got a csv file, where the first elements in each row contain sometimes an additional comma as part of the name. Since not all elements are put in quotation marks it will result in a messed up dataframe. I want to regard only the last n commas…
-1
votes
1 answer

Assistance needed regarding dictionary syntax in Python

I have a syntax issue while using dictionary for the first time. I hope you guys can help me with it. I'm reading election data from a .csv file. I'm trying to put the names and votes for each candidate into a dictionary so the display would look…