urgent please help

I’ve written all of my code but it won’t do rmarkdown html. It keeps getting errors. My teacher said he won’t accept it unless it’s in rmarkdown html. PLEASE HELP.

In rmarkdown there are text chunks and code chunks. Your readcsv call is in a ? chunk.

in addition to needing your code to be in a code chunk; advise you not to have install.package commands in an rmarkdown; also if your teacher is expected to be able to run your markdown, then you are guaranteeing an error when they run it if you set a working directory, that they wont have when they come to do so.
Conventionally the working directory will be the location of the markdown file, so it would probably better to keep your rmarkdown in the folder along with the data it needs, and then presumably it can all be transferred together for your teacher to review.

Like @nirgrahamuk said your code needs to be within a code chunk in an R markdown file.

You should also make sure that all your data is included in the folder with the Rmd file.

Your teacher may expect you to knit the Rmd file into an html file. You can do this within Rstudio using the knit button which is located right above the code window.

Please review the Policy and FAQ Item

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.