gravatar

onduuuu

Andrew Lau

Recently Published

JHU Course 9 Assign 4
JHU Course 9 Assign 4
Statistical Analysis the ‘ToothGrowth’ dataset
Linear models are used to analyse the built in R data set “ToothGrowth”. The effect of supplements (vitamin C (VC) and orange juice (OJ)) at three different dose levels (0.5, 1, and 2 mg/day) on the length of odontoblasts in 60 guinea pigs are examined.
JHU Course 9 - Assignment 3
JHU Course 9 - Assignment 3
JHU Course 9 Assign 2
JHU Course 9 Assign 2
Power Sets
A bit about power sets as well as an algorithm to generate power sets and an implementation in Python.
Python in R Markdown Files
What a world we live in... Now, not only can we call Python from within R, we can pass data back and forth between R and Python and knit Python up into an R Markdown file. We can have our cake and eat it too! (Check out https://rstudio.github.io/reticulate/index.html for more information about the reticulate package) Here we focus on how to call Python from an R Markdown file.
Selection Sort
The Selection Sort algorithm is implemented here and the time complexity vs. number of elements examined. The Selection Sort was written in Python and passed to R for plotting.
Simple vs. Binary Searches
We demonstrate two search algorithms (e.g. finding an element from a data structure - in this case a list), the Simple Search and the Binary Search. The relationship between the number of steps and the size of the data structure, n, is also examined. Through simulations, we see that the Simple Search runs in linear time (big O(n)) and that the Binary Search runs in log time (big O(log(n))). The search algorithms are written in Python and then passed to R for plotting.
Fuel efficiency: automatic vs. manual transmission
An investigation into the impact of transmission on fuel efficiency using the "mtcars" dataset.