Monday, August 2, 2021

Ordinal Logistic Regression (OLR) in Neural Network (NN) using R

 library(neuralnet)library("ISLR")#load datadata<- read.csv(file.choose())colnames(data)smp_size <- floor(0.75 * nrow(data))train_ind <- sample(seq_len(nrow(data)), size = smp_size)train <- mtcars[train_ind, ]test <- mtcars[-train_ind, ]#divide training and testing datamean_data...

Sunday, August 1, 2021

Logistic Regression with Confusion Matrix in R

 #Coded by Tawkir Ahmed library(ggplot2) #USed for plotting datalibrary(dplyr) #Used to extract columns in the datalibrary(rms) #Used to extract p-value from logistic modellibrary(aod)library(caret)# logistic modelrail <- read.csv(choose.files())   #trainingtest<- read.csv(choose.files()) ...