Posts

Showing posts from April, 2025

R Package: uniqueread

 R Package: uniqueread Github:  https://github.com/christilly/uniqueread

Module 12 Assignment

Image
 Module 12 Assignment GitHub uniqueread package repository:  https://github.com/christilly/uniqueread HTML Markdown:      I created a  Markdown file in R for my package uniqueread. I broke down my functions into sections, explaining the purpose of each.      At first I described the package purpose and the required libraries.       Next I explain how to import data from Goodreads and how to remove unrated books from the analysis.      Next I showed how to calculate the residuals for each book (user rating - average rating). I also showed how to calculate average, standard deviation, highest, and lowest residuals, as well as how to find the associated book titles for the highest/lowest residuals.  Lastly, I showed my function for displaying the residuals data visually in a distribution histogram.       The whole process required a big learning curve. I have been working on the package...

Module 11 Assignment

Image
 Module 11 Assignment Identify the bug in example code: tukey_multiple <- function(x) {     outliers <- array(TRUE,dim=dim(x))     for (j in 1:ncol(x))      {      outliers[,j] <- outliers[,j] && tukey.outlier(x[,j])      }  outlier.vec <- vector(length=nrow(x))      for (i in 1:nrow(x))      { outlier.vec[i] <- all(outliers[i,]) } return(outlier.vec) } My first step was to run the code to test the function. I received this error: This helped me narrow down my search of the bug to the second for loop in the function. I wanted to run debug on the function, however, I learned I have to load the function into my local environment first. I changed the working directory to where the file is located on my device and tried to source the R file as shown below.  However, sourcing the R file did not work because the file has an err...