Publications by Shariq Mian

Data605_HW14

11.05.2023

1 f <- function(x) 1/(1-x) f_prime <- function(x) 1/(1-x)^2 f_double_prime <- function(x) 2/(1-x)^3 f_triple_prime <- function(x) 6/(1-x)^4 f_prime(0) # 1 ## [1] 1 f_double_prime(0) # 2 ## [1] 2 f_triple_prime(0) # 6 ## [1] 6 f_n <- function(n, x) factorial(n)*(1-x)^(n+1) sum_n <- function(x) sum(sapply(0:Inf, function(n) x^n/factorial(n))) ...

37 sym

Data622 HW4

31.01.2023

Overview This is a banking and marketing dataset that was created by Sérgio Moro (ISCTE-IUL), Paulo Cortez (Univ. Minho) and Paulo Rita (ISCTE-IUL).It is a binary classification problem with the goal of predicting if the client will subscribe a bank term deposit (variable y). ## Warning in !is.null(rmarkdown::metadata$output) && rmarkdown:...

5253 sym R (21176 sym/82 pcs) 24 img 1 tbl

Data605_HW6

03.10.2022

Question 1 A bag contains 5 green and 7 red jellybeans. How many ways can 5 jellybeans be withdrawn from the bag so that the number of green ones withdrawn will be less than 2? Q1=choose(5,1)*choose(7,4)+choose(5,0)*choose(7,5) Q1 #5C1∗7C4+5C0∗7C5=196 ## [1] 196 Question A certain congressional committee consists of 14 senators and 13 repre...

2457 sym

ASSIGNMENT 1

27.07.2021

HW1 Question 1 fct=1 num=12 for (i in 1:num) { fct=fct*i } print(fct) ## [1] 479001600 Question 2 vect=(seq(20,50,5)) print(vect) ## [1] 20 25 30 35 40 45 50 Question 3 Quadratic Equation Form =ax^2+bx+c Equation = function(a, b, c) { if (a == 0){ return ('a cannot be 0') } x = (b^2 - 4*a * c) output1 = (-b + sqrt(x))/(2*a) outp...

85 sym R (383 sym/6 pcs)

HW2

02.08.2021

Importing RCurl library for reading github url library(RCurl) Reading and importing csv from my github data <- getURL("https://raw.githubusercontent.com/mianshariq/SPS_Bridge/main/MplsStops.csv?token=AQ2YTI45J2CA2CL3G5UNK4TBA5OGM", ssl.verifypeer=0L, followlocation=1L) df=read.csv(text=data) First 5 rows of my data head(df) Summary of my data su...

266 sym R (3252 sym/10 pcs)

Project 4

16.11.2021

Libraries library(tm) library(knitr) library(plyr) library(wordcloud) library(tidyverse) library(tm) library(magrittr) library(data.table) library(randomForest) library(tidymodels) library(caTools) library(gmailr) Accessing ham email messages ham="~/Shariq School/SPS/Data 607/SpamHam/easy_ham" count_ham=length(list.files(path = ham))...

380 sym R (10009695 sym/26 pcs) 2 img

Project_Proposal

08.12.2021

library(ggplot2) Data Preparation # load data df=read.csv("https://github.com/mianshariq/SPS/raw/dab24b98c3c1d48b96ea619c01caacfefa916386/Data%20606/Projects/NFL%20Data.csv") df1=read.csv("https://github.com/mianshariq/SPS/raw/4fe676d9723fea08abb22f2021d644177dc16698/Data%20606/Projects/NFL%20Data%20Min.csv") Research question You should phr...

1302 sym R (5082 sym/12 pcs) 1 img

Final_Project

08.12.2021

library(dplyr) ## ## Attaching package: 'dplyr' ## The following objects are masked from 'package:stats': ## ## filter, lag ## The following objects are masked from 'package:base': ## ## intersect, setdiff, setequal, union library(tidyr) library(ggplot2) library(ggplot2) library(qtl) Indroduction Abstract Your team should not...

4982 sym R (20901 sym/55 pcs) 8 img

Data 606 HW8

08.11.2021

Nutrition at Starbucks, Part I. (8.22, p. 326) b (a) Describe the relationship between number of calories and amount of carbohydrates (in grams) that Starbucks food menu items contain. There is a positive relationship between number of calories and amount of carbohydrates. There is a near linearity in the plot. (b) In this scenario, what are t...

5878 sym R (469 sym/14 pcs) 10 img

Data607_HW9

25.10.2021

Assignment The New York Times web site provides a rich set of APIs, as described here: https://developer.nytimes.com/apis You’ll need to start by signing up for an API key. Your task is to choose one of the New York Times APIs, construct an interface in R to read in the JSON data, and transform it into an R DataFrame. Libraries library(tidyver...

739 sym R (3185 sym/19 pcs) 2 img