Publications by R on notast

Explaining Predictions: Random Forest Post-hoc Analysis (randomForestExplainer package)

30.08.2019

Recap This is a continuation on the explanation of machine learning model predictions. Specifically, random forest models. We can depend on the random forest package itself to explain predictions based on impurity importance or permutation importance. Today, we will explore external packages which aid in explaining random forest predictions. Ext...

10489 sym R (5781 sym/16 pcs) 16 img

Explaining Predictions: Boosted Trees Post-hoc Analysis (Xgboost)

11.10.2019

Recap We’ve covered various approaches in explaining model predictions globally. Today we will learn about another model specific post hoc analysis. We will learn to understand the workings of gradient boosting predictions. Like past posts, the Clevaland heart dataset as well as tidymodels principle will be used. Refer to the first post of this...

5533 sym R (3304 sym/7 pcs) 4 img

`R` you ready for python (gentle introduction to reticulate package)’

10.01.2020

Just like how Thanos claimed to be inevitable in The Avengers, the direct or indirect use of python has become inevitable for R users in recent years. Fret not R users, you don’t have to abandon your favourite IDE, Rstudio, when using python. With the reticulate package you can use python in Rstudio and even have a mixture of R and python code ...

4760 sym R (2198 sym/19 pcs)

What R you in python? (`R` vectors)

18.01.2020

reticulate allows us to toggle between R and python in the same session, callling R objects when running python scripts and vice versa. When calling R data structures in python, the R structures are converted to the equivalent python structures where applicable. However, like translating English to Mandarin, translating R structures to python may...

4668 sym R (1968 sym/23 pcs)

What `R` you? (R list in python)

25.01.2020

Previously, we uncovered what are R vectors in python. In this post, we will convert R lists in python. A R list is a python … Like R vectors, it depends. A R list will behave differently in python depending if it is named or not. Unnamed R list An unnamed list in R is a python list but this does not mean R and python lists have the exact sam...

3517 sym R (1693 sym/16 pcs)

What `R` you? (R matrixes and R arrays in python)

11.02.2020

Recap Previously in this series, we discovered the equivalent python data structures of the following R data structures: vectors lists In this post, we will look at translating R arrays (and matrixes) into python. 1D R array A 1D R array prints like a vector. library(tidyverse) library(reticulate) py_run_string("import numpy as np") py_run_str...

4324 sym R (1699 sym/23 pcs)

What `R` you? (R dataframe vs python dataframe)

16.02.2020

Recap Previously in this series, we discovered the equivalent python data structures for the following R data structures: vectors lists arrays/matrixes In this post, we will look at translating R data frames into python. We will also compare and contrast data frames in R and python. R data frame is a python… Pretty straight forward, a R data...

8589 sym R (10605 sym/46 pcs) 2 tbl

Predicting pneumonia outcomes: EDA part 1

04.08.2020

Intro Data dictionary EDA blueprint Outcome Discard the noise 1 Other_ related category 2 Pt_ Patient related category Appropriate patients Case_number Age 3 R_ Radiology related category Effusion and effusion site On chest x-ray ( R_CXR_effusion, R_CXR_effusionSite) On CT chest (R_CT_effusion, R_CT_effusionSite) 4 SS_ Category related to sign...

11375 sym R (30906 sym/43 pcs) 20 img

Predicting pneumonia outcomes: EDA part 2

10.08.2020

Intro 9 Lab_ related category Missing Lab values Outlier Lab values High Lab_Hb levels Low Lab_Neu High Lab_Sugar 10 CS_ cultures related category 11 Abx_ antibiotics related category 11i Class of empirical antibiotics given 11ii Antibiotics given Number of antibiotics given 11iii Duration of antibiotics 12 Care_ continuum of care status categ...

7604 sym R (22259 sym/38 pcs) 26 img

Predicting pneumonia outcomes: Feature Engineering

17.08.2020

Intro This post is a supplementary material for an assignment. The assignment is part of the Augmented Machine Learning unit for a Specialised Diploma in Data Science for Business. The aim of the assignment is to use DataRobot for predictive modelling. Exploratory data analysis and feature engineering will be done here in R before the data is imp...

4048 sym R (8026 sym/19 pcs) 14 img