The screenshot below shows the data inside our EmployeeSales.txt file, and we are going use this file to demonstrate the R read.table function.
For example, if you want the top 5 records, use nrows = 5 in the read table function in R. You can use this argument to restrict the number of rows to read.
#Reading cdf files r how to
Let us see how to use this R read table function and manipulate the data in R Programming with an example. The R read.table function is very useful to import the data from text files from the file system & URLs and store the data in a Data Frame.