Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2 Make a set of R lines based on the following guidelines. ( each one has 4 points) Make some simple vectors of data (numerical

2 Make a set of R lines based on the following guidelines. ( each one has 4 points)

  1. Make some simple vectors of data (numerical or text) using the c() command.
  2. Use the scan() command to enter numerical data; this is quicker as the items can be separated by simple spaces (spaces are the default but other separators can be used).
  3. Use the scan() command to enter some text; this requires an extra instruction, what = character. Items still only require separation with space and do not need to be enclosed in quotes.
  4. Text items are dealt with similarly to step 3: you use the what = character instruction.
  5. Now show how to use the scan() command to read a simple text file.
  6. This is a convenient time to show how to alter the working directory using the setwd() command. The dir() command can also be demonstrated.
  7. Now show how to read larger, and potentially more complicated data from disk using the read.csv() command.
  8. Use files in a variety of formats (comma delimited, tab, space) to give your class some practice at using the read.csv() command and the variants such as read.table()

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

LO3 Define the difference between job satisfaction and engagement.

Answered: 1 week ago