Module 11: Debugging in R

 Upon loading in the given code example for this assignment, the first thing I attempted to do was to simply run the code and see what would happen in order to better isolate a potential issue. That gave me the error shown here:

Clearly something was amiss with the return argument, so that was the line I checked. It became obvious looking at it further that said argument shouldn't have been part of the same line as the line in brackets, so I isolated it into its own line.
Making this fix allowed the code to be properly executed, and for the function to be created. Next was testing the function with an example matrix. Initially, it failed with this error:

This exposed the other issue with the functions code; it seemed to depend on another function dubbed tukey.outlier that was completely missing, and therefore was interfering with the function's ability to be properly used. Commenting the line out and redefining the function allowed it to properly work once more.

Resulting code can be found here: https://github.com/Retrolovania/R_Programming/blob/main/Module%2011.R






Comments

Popular posts from this blog

Module 6: Our First Graph

LIS 4317 Final Project: R Chart showing Game Price changes over time

Final Project: DescribeR v1.0.0