Turn extraction list to csv file
问题 I have uploaded a raster file and polyline shapefile into R and use the extract function to to extract the data from every pixel along the polyline. How do I turn the list output by extract into a CSV file? 回答1: If I understand what it is you're asking, I think you could resolve your situation by using unlist(). d <- c(1:10) # creates a sample data frame to use d <- as.list(d) # converts the data frame into a list d <- unlist(d) # converts the list into a vector 回答2: Always include a simple