content large_stringlengths 0 6.46M | path large_stringlengths 3 331 | license_type large_stringclasses 2
values | repo_name large_stringlengths 5 125 | language large_stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 4 6.46M | extension large_stringclasses 75
values | text stringlengths 0 6.46M |
|---|---|---|---|---|---|---|---|---|---|
library(norm2)
## run EM on fake data with missing values
set.seed(1234)
simdata <- data.frame(
Y1=rnorm(10), Y2=rnorm(10), Y3=rnorm(10), X1=rnorm(10) )
simdata$Y3[7] <- simdata$Y2[3]<- NA
emResult <- emNorm( cbind(Y1,Y2,Y3) ~ X1, data=simdata )
## predictive mean imputation under MLE
imp <- impNorm( emResult, met... | /norm2/tests/impTests.R | no_license | uscensusbureau/norm2 | R | false | false | 1,115 | r | library(norm2)
## run EM on fake data with missing values
set.seed(1234)
simdata <- data.frame(
Y1=rnorm(10), Y2=rnorm(10), Y3=rnorm(10), X1=rnorm(10) )
simdata$Y3[7] <- simdata$Y2[3]<- NA
emResult <- emNorm( cbind(Y1,Y2,Y3) ~ X1, data=simdata )
## predictive mean imputation under MLE
imp <- impNorm( emResult, met... |
\name{piaac.mean.pv}
\alias{piaac.mean.pv}
\title{
Calculates mean achievement score for PIAAC data
}
\description{
piaac.mean.pv uses ten plausible values to calculate the mean achievement score and its standard error
}
\usage{
piaac.mean.pv(pvlabel, by, data, export = FALSE, name = "output", folder = getwd())
}
\arg... | /man/piaac.mean.pv.Rd | no_license | eldafani/intsvy | R | false | false | 1,386 | rd | \name{piaac.mean.pv}
\alias{piaac.mean.pv}
\title{
Calculates mean achievement score for PIAAC data
}
\description{
piaac.mean.pv uses ten plausible values to calculate the mean achievement score and its standard error
}
\usage{
piaac.mean.pv(pvlabel, by, data, export = FALSE, name = "output", folder = getwd())
}
\arg... |
# Installing packages
install.packages("naivebayes", dependencies=TRUE, type="source")
# Load the packages
library(naivebayes)
# data set-up: same as K-NN
x_variables<-c("age", "race_group", "discharge_status", "ischemic_cardiomyopathy", "obesity", "comorbidity_score", "Loop_diuretics","Other_diuretics")
x_pr... | /8 Naive Bayes.R | no_license | Sakampavankumar/ML_using_R | R | false | false | 947 | r | # Installing packages
install.packages("naivebayes", dependencies=TRUE, type="source")
# Load the packages
library(naivebayes)
# data set-up: same as K-NN
x_variables<-c("age", "race_group", "discharge_status", "ischemic_cardiomyopathy", "obesity", "comorbidity_score", "Loop_diuretics","Other_diuretics")
x_pr... |
library(tidyverse)
library(tidygraph)
library(networkD3)
library(ggraph)
library(viridis)
source(here::here("code", "fun_tables.R")) #for make_table funs
setup_graph <- function(toptable_data = master_top_table, bottomtable_data = master_bottom_table, gene_symbol, threshold = 10) {
#make empty tibble
dep_network ... | /code/fun_graphs.R | no_license | matthewhuang457/ddh | R | false | false | 8,575 | r | library(tidyverse)
library(tidygraph)
library(networkD3)
library(ggraph)
library(viridis)
source(here::here("code", "fun_tables.R")) #for make_table funs
setup_graph <- function(toptable_data = master_top_table, bottomtable_data = master_bottom_table, gene_symbol, threshold = 10) {
#make empty tibble
dep_network ... |
library(geoSpectral)
### Name: spc.export.xlsx
### Title: Exports a 'Spectra' object into Excel format.
### Aliases: spc.export.xlsx spc.export.xlsx,Spectra-method
### ** Examples
## Not run:
##D sp=spc.example_spectra()
##D if("xlsx" %in% installed.packages())
##D spc.export.xlsx(sp,"test.xlsx")
## End(N... | /data/genthat_extracted_code/geoSpectral/examples/spc.export.xlsx.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 332 | r | library(geoSpectral)
### Name: spc.export.xlsx
### Title: Exports a 'Spectra' object into Excel format.
### Aliases: spc.export.xlsx spc.export.xlsx,Spectra-method
### ** Examples
## Not run:
##D sp=spc.example_spectra()
##D if("xlsx" %in% installed.packages())
##D spc.export.xlsx(sp,"test.xlsx")
## End(N... |
\name{CCA}
\alias{CCA}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
function performing a Canonical Correlation Analysis on a given data table or on (simulated) data streams.
}
\description{
This function permits user to perform fast Canonical Correlation Analysis on (high dimensional on-line)... | /man/CCA.Rd | no_license | cran/factas | R | false | false | 6,264 | rd | \name{CCA}
\alias{CCA}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
function performing a Canonical Correlation Analysis on a given data table or on (simulated) data streams.
}
\description{
This function permits user to perform fast Canonical Correlation Analysis on (high dimensional on-line)... |
rentfile = read.csv("C:/Users/Pranay Anand/Desktop/Project2/rent.csv")
str(rentfile)
head(rentfile)
plot(rent~size, data = rentfile)
#corelation coefficients b/w rent & size
cor(rentfile$rent, rentfile$size)
model1 = lm(rent~size, data = rentfile)
print(model1)
summary(model1)
abline(model1, col = "blue", lty = 3, lwd ... | /rent problem.R | no_license | pranayanand123/rent-problem | R | false | false | 449 | r | rentfile = read.csv("C:/Users/Pranay Anand/Desktop/Project2/rent.csv")
str(rentfile)
head(rentfile)
plot(rent~size, data = rentfile)
#corelation coefficients b/w rent & size
cor(rentfile$rent, rentfile$size)
model1 = lm(rent~size, data = rentfile)
print(model1)
summary(model1)
abline(model1, col = "blue", lty = 3, lwd ... |
##' QGIS Algorithm provided by GRASS v.kernel.vector (grass7:v.kernel.vector)
##'
##' @title QGIS algorithm v.kernel.vector
##'
##' @param input `source` - Name of input vector map with training points. Path to a vector layer.
##' @param net `source` - Name of input network vector map. Path to a vector layer.
##' @para... | /R/grass7_v_kernel_vector.R | permissive | VB6Hobbyst7/r_package_qgis | R | false | false | 4,982 | r | ##' QGIS Algorithm provided by GRASS v.kernel.vector (grass7:v.kernel.vector)
##'
##' @title QGIS algorithm v.kernel.vector
##'
##' @param input `source` - Name of input vector map with training points. Path to a vector layer.
##' @param net `source` - Name of input network vector map. Path to a vector layer.
##' @para... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/diann-R.R
\name{diann_load}
\alias{diann_load}
\title{Read a table as a data frame}
\usage{
diann_load(file)
}
\arguments{
\item{file}{file name}
}
\description{
Read a table as a data frame
}
| /man/diann_load.Rd | permissive | BenoitBe/diann-rpackage | R | false | true | 271 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/diann-R.R
\name{diann_load}
\alias{diann_load}
\title{Read a table as a data frame}
\usage{
diann_load(file)
}
\arguments{
\item{file}{file name}
}
\description{
Read a table as a data frame
}
|
`quantile.outliers.pond` <- function(data, dfunc = depth.RP, nb = 200, suav = 0.05, ...)
{
functions = t(data$y)
n <- dim(functions)[1]
m <- dim(functions)[2]
if(is.null(n) && is.null(m))
stop("I do not have a matrix.")
d = dfunc(data,...)$prof
quantiles <- numeric(nb)
... | /modified_rainbow/R/quantile.outliers.pond.R | no_license | Chris7462/Modified-Rainbow | R | false | false | 783 | r | `quantile.outliers.pond` <- function(data, dfunc = depth.RP, nb = 200, suav = 0.05, ...)
{
functions = t(data$y)
n <- dim(functions)[1]
m <- dim(functions)[2]
if(is.null(n) && is.null(m))
stop("I do not have a matrix.")
d = dfunc(data,...)$prof
quantiles <- numeric(nb)
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Con_Sampling_2D.R
\name{Con_Sampling_2D}
\alias{Con_Sampling_2D}
\title{Conditionally sampling a two-dimensional dataset}
\usage{
Con_Sampling_2D(Data_Detrend, Data_Declust, Con_Variable, u = 0.97, Thres = NA)
}
\arguments{
\item{Dat... | /man/Con_Sampling_2D.Rd | no_license | rjaneUCF/MultiHazard | R | false | true | 2,107 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Con_Sampling_2D.R
\name{Con_Sampling_2D}
\alias{Con_Sampling_2D}
\title{Conditionally sampling a two-dimensional dataset}
\usage{
Con_Sampling_2D(Data_Detrend, Data_Declust, Con_Variable, u = 0.97, Thres = NA)
}
\arguments{
\item{Dat... |
setwd(normalizePath(dirname(R.utils::commandArgs(asValues=TRUE)$"f")))
source("../../scripts/h2o-r-test-setup.R")
# Compare within-cluster sum of squared error
test.kmstand.golden <- function() {
# Import data:
Log.info("Importing ozone.csv data...")
ozoneR <- read.csv(locate("smalldata/glm_test/ozone.csv"), ... | /h2o-r/tests/testdir_golden/runit_km2_2_golden.R | permissive | h2oai/h2o-3 | R | false | false | 2,525 | r | setwd(normalizePath(dirname(R.utils::commandArgs(asValues=TRUE)$"f")))
source("../../scripts/h2o-r-test-setup.R")
# Compare within-cluster sum of squared error
test.kmstand.golden <- function() {
# Import data:
Log.info("Importing ozone.csv data...")
ozoneR <- read.csv(locate("smalldata/glm_test/ozone.csv"), ... |
x = 1:10000
y = (log10(sin(x^(-3))))
plot(x,y) | /lesson1.R | no_license | masharadina/mathmod | R | false | false | 47 | r |
x = 1:10000
y = (log10(sin(x^(-3))))
plot(x,y) |
library(tidyverse);
results_ep <- read_csv('./nas-alpine/results.csv') %>% mutate(experiment = 'NAS EP')
results_ondes3d <- read_csv('./ondes3d-alpine/results.csv') %>% mutate(experiment = 'Ondes3D')
results <-bind_rows(results_ep, results_ondes3d)
results <- results %>%
mutate(time=time/1000) %>%
group_by(experi... | /wscad/paper/results/plot-ep-essai-alpine.R | no_license | guilhermealles/hpc-containers | R | false | false | 1,464 | r | library(tidyverse);
results_ep <- read_csv('./nas-alpine/results.csv') %>% mutate(experiment = 'NAS EP')
results_ondes3d <- read_csv('./ondes3d-alpine/results.csv') %>% mutate(experiment = 'Ondes3D')
results <-bind_rows(results_ep, results_ondes3d)
results <- results %>%
mutate(time=time/1000) %>%
group_by(experi... |
## point to current project folder
setwd("/Users/bikash/repos/bigdata/ExData_Plotting1")
## data load
########################################################################################################################
##q1: The dataset has 2,075,259 rows and 9 columns. First calculate a rough estimate of
#how m... | /plot1.R | no_license | bikash/coursera-exploratory-data-analysis | R | false | false | 1,693 | r |
## point to current project folder
setwd("/Users/bikash/repos/bigdata/ExData_Plotting1")
## data load
########################################################################################################################
##q1: The dataset has 2,075,259 rows and 9 columns. First calculate a rough estimate of
#how m... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/reg-aggregate.R
\name{agg_region_all}
\alias{agg_region_all}
\title{Build regional aggregations for selected metric}
\usage{
agg_region_all(df, regs, measure, func, grps = c("all_sports", "hunt", "fish"))
}
\arguments{
\item{df}{input summary... | /man/agg_region_all.Rd | no_license | southwick-associates/sadashreg | R | false | true | 917 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/reg-aggregate.R
\name{agg_region_all}
\alias{agg_region_all}
\title{Build regional aggregations for selected metric}
\usage{
agg_region_all(df, regs, measure, func, grps = c("all_sports", "hunt", "fish"))
}
\arguments{
\item{df}{input summary... |
rm(list = ls(all.names = TRUE))
# Load Libraries
library(stats)
library(tidyr)
library(stringr)
library(broom)
library(ggplot2)
library(PrjOptiAlloc)
library(knitr)
library(kableExtra)
library(tibble)
library(forcats)
library(REconTools)
library(PrjOptiAlloc)
library(knitr)
library(kableExtra)
library(dplyr)
# RM... | /.Rprofile | permissive | FanWangEcon/PrjOptiAlloc | R | false | false | 835 | rprofile | rm(list = ls(all.names = TRUE))
# Load Libraries
library(stats)
library(tidyr)
library(stringr)
library(broom)
library(ggplot2)
library(PrjOptiAlloc)
library(knitr)
library(kableExtra)
library(tibble)
library(forcats)
library(REconTools)
library(PrjOptiAlloc)
library(knitr)
library(kableExtra)
library(dplyr)
# RM... |
#'Compute or Extract Silhouette Information from Clustering based on similarity matrix.
#'
#'Silhouette refers to a method of interpretation and validation of consistency within clusters of data.
#'The technique provides a succinct graphical representation of how well each object lies within its cluster (From Wik... | /R/Valiation.R | no_license | gregpoore/CancerSubtypes | R | false | false | 22,872 | r |
#'Compute or Extract Silhouette Information from Clustering based on similarity matrix.
#'
#'Silhouette refers to a method of interpretation and validation of consistency within clusters of data.
#'The technique provides a succinct graphical representation of how well each object lies within its cluster (From Wik... |
#' Create a new formula branch.
#'
#' @examples
#' # Define a formula branch.
#' model_specifications <- formula_branch(
#' y ~ femininity,
#' y ~ femininity + hurricane_strength,
#' y ~ femininity * hurricane_strength
#' )
#' # Create a mverse, add the branch.
#' mv <- create_multiverse(hurricane) %>%
#' add_f... | /R/formula_branch.R | no_license | mverseanalysis/mverse | R | false | false | 7,023 | r | #' Create a new formula branch.
#'
#' @examples
#' # Define a formula branch.
#' model_specifications <- formula_branch(
#' y ~ femininity,
#' y ~ femininity + hurricane_strength,
#' y ~ femininity * hurricane_strength
#' )
#' # Create a mverse, add the branch.
#' mv <- create_multiverse(hurricane) %>%
#' add_f... |
require(rCharts)
shinyServer(function(input, output) {
output$myChart <- renderChart({
n1 <- nPlot(sc_shortfall ~ state_and_ut, data=analysis_data[1:35,], type="discreteBarChart", staggerLabels=TRUE)
n1$addParams(dom = 'myChart')
return(n1)
})
})
| /general-healthcare-india/webapp/server.R | no_license | nehiljain/data-analysis-projects | R | false | false | 263 | r | require(rCharts)
shinyServer(function(input, output) {
output$myChart <- renderChart({
n1 <- nPlot(sc_shortfall ~ state_and_ut, data=analysis_data[1:35,], type="discreteBarChart", staggerLabels=TRUE)
n1$addParams(dom = 'myChart')
return(n1)
})
})
|
## Create a special "matrix", which is a list containing
## a function to
## - set the value of the matrix
## - get the value of the matrix
## - set the value of the inverse matrix
## - get the value of the inverse matrix
makeCacheMatrix <- function(x = matrix())
{
i <- NULL
set <- function(y) {
... | /cachematrix.R | no_license | bakshi-varun/ProgrammingAssignment2 | R | false | false | 924 | r | ## Create a special "matrix", which is a list containing
## a function to
## - set the value of the matrix
## - get the value of the matrix
## - set the value of the inverse matrix
## - get the value of the inverse matrix
makeCacheMatrix <- function(x = matrix())
{
i <- NULL
set <- function(y) {
... |
library(testthat)
library(magrittr)
library(recipes)
data("biomass")
rec <- recipe(HHV ~ carbon + hydrogen + oxygen + nitrogen + sulfur,
data = biomass)
test_that('spatial sign', {
sp_sign <- rec %>%
step_center(carbon, hydrogen) %>%
step_scale(carbon, hydrogen) %>%
step_spatialsign(carb... | /tests/testthat/test_spatialsign.R | no_license | lionel-/recipes | R | false | false | 959 | r | library(testthat)
library(magrittr)
library(recipes)
data("biomass")
rec <- recipe(HHV ~ carbon + hydrogen + oxygen + nitrogen + sulfur,
data = biomass)
test_that('spatial sign', {
sp_sign <- rec %>%
step_center(carbon, hydrogen) %>%
step_scale(carbon, hydrogen) %>%
step_spatialsign(carb... |
# https://www.kaggle.com/kostoglot/winning-solution#L144
### Loading required libraries
library(plyr)
library(tidyverse)
library(jsonlite)
library(magrittr)
library(caret)
library(lubridate)
library(lightgbm)
library(foreach)
### Defining types of extracted attributes
ctypes <- cols(fullVisitorId = col_character(),... | /kaggle/Google_Revenue_Predict/rank_1.R | no_license | Happyccc/7days_ml | R | false | false | 11,106 | r | # https://www.kaggle.com/kostoglot/winning-solution#L144
### Loading required libraries
library(plyr)
library(tidyverse)
library(jsonlite)
library(magrittr)
library(caret)
library(lubridate)
library(lightgbm)
library(foreach)
### Defining types of extracted attributes
ctypes <- cols(fullVisitorId = col_character(),... |
weightedPortfolio = function(R, weights)
{
R = na.omit(R[, names(weights)])
res = xts(apply(R, MARGIN = 1, FUN = function(r)return(sum(r*weights))), order.by = index(R))
index(res) = as.Date(index(res))
return(res)
}
| /Functions/weightedPortfolio.R | no_license | bplloyd/R-risk-mgmt | R | false | false | 225 | r | weightedPortfolio = function(R, weights)
{
R = na.omit(R[, names(weights)])
res = xts(apply(R, MARGIN = 1, FUN = function(r)return(sum(r*weights))), order.by = index(R))
index(res) = as.Date(index(res))
return(res)
}
|
# Find the expansion of a geometric set
expansion <- function(C,X,sigma)
{
# compute the minimum distance of X to C
D_XC <- distance(X,as.matrix(X[C,]))
distance_to_C <- apply(D_XC,1,FUN = function(d){min(d)})
# return the sigma expansion set
return(which(distance_to_C <= sigma))
}
# Compute the density c... | /code/geometric_methods.R | no_license | ajgreen93/local_spectral_density_clustering | R | false | false | 9,352 | r | # Find the expansion of a geometric set
expansion <- function(C,X,sigma)
{
# compute the minimum distance of X to C
D_XC <- distance(X,as.matrix(X[C,]))
distance_to_C <- apply(D_XC,1,FUN = function(d){min(d)})
# return the sigma expansion set
return(which(distance_to_C <= sigma))
}
# Compute the density c... |
library(rgbif)
### Name: gbif_names
### Title: View highlighted terms in name results from GBIF.
### Aliases: gbif_names
### ** Examples
## Not run:
##D # browse=FALSE returns path to file
##D gbif_names(name_lookup(query='snake', hl=TRUE), browse=FALSE)
##D
##D (out <- name_lookup(query='canada', hl=TRUE, limit=... | /data/genthat_extracted_code/rgbif/examples/gbif_names.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 547 | r | library(rgbif)
### Name: gbif_names
### Title: View highlighted terms in name results from GBIF.
### Aliases: gbif_names
### ** Examples
## Not run:
##D # browse=FALSE returns path to file
##D gbif_names(name_lookup(query='snake', hl=TRUE), browse=FALSE)
##D
##D (out <- name_lookup(query='canada', hl=TRUE, limit=... |
#use this to open a shell in CentOS 6 that can be used to run the scripts
#scl enable devtoolset-1.1 bash
#source("~/Dropbox/PINLab/Projects/R_Code/TPMNE/Scripts/TPME_Run_SS_Out_of_Function.R")
setwd("~/Dropbox/PINLab/Projects/R_Code/TPMNE")
#requires RcppArmadillo and all dependenices be installed
#install.packages... | /Scripts/TPME_Run_SS_Out_of_Function.R | no_license | matthewjdenny/TPME | R | false | false | 11,335 | r |
#use this to open a shell in CentOS 6 that can be used to run the scripts
#scl enable devtoolset-1.1 bash
#source("~/Dropbox/PINLab/Projects/R_Code/TPMNE/Scripts/TPME_Run_SS_Out_of_Function.R")
setwd("~/Dropbox/PINLab/Projects/R_Code/TPMNE")
#requires RcppArmadillo and all dependenices be installed
#install.packages... |
## The following functions can be used to create a new matrix, and calculate
## its inverse matrix only in case it still has not been created.
## The function makeCacheMatrix creates an object containing both the given
## matrix and a variable for its inverse matrix. It contains the required
## functions to create and... | /cachematrix.R | no_license | pmartincalvo/ProgrammingAssignment2 | R | false | false | 1,391 | r | ## The following functions can be used to create a new matrix, and calculate
## its inverse matrix only in case it still has not been created.
## The function makeCacheMatrix creates an object containing both the given
## matrix and a variable for its inverse matrix. It contains the required
## functions to create and... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/faraway-package.R
\docType{data}
\name{dvisits}
\alias{dvisits}
\title{Doctor visits in Australia}
\format{
A data frame with 5190 observations on the following 19 variables.
\describe{ \item{sex}{1 if female, 0 if male} \item{age}{Age
in yea... | /man/dvisits.Rd | no_license | cran/faraway | R | false | true | 2,927 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/faraway-package.R
\docType{data}
\name{dvisits}
\alias{dvisits}
\title{Doctor visits in Australia}
\format{
A data frame with 5190 observations on the following 19 variables.
\describe{ \item{sex}{1 if female, 0 if male} \item{age}{Age
in yea... |
library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/Correlation/lymphoid.csv",head=T,sep=",")
x = as.matrix(mydata[,4:ncol(mydata)])
y = as.matrix(mydata[,1])
set.seed(123)
glm = cv.glmnet(x,y,nfolds=10,type.measure="mae",alpha=0.8,family="gaussian",standardize=FALSE)
sink('./lymphoid_084.txt',append=T... | /Model/EN/Correlation/lymphoid/lymphoid_084.R | no_license | esbgkannan/QSMART | R | false | false | 354 | r | library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/Correlation/lymphoid.csv",head=T,sep=",")
x = as.matrix(mydata[,4:ncol(mydata)])
y = as.matrix(mydata[,1])
set.seed(123)
glm = cv.glmnet(x,y,nfolds=10,type.measure="mae",alpha=0.8,family="gaussian",standardize=FALSE)
sink('./lymphoid_084.txt',append=T... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/outlier_analysis.R
\name{outlier_analysis}
\alias{outlier_analysis}
\title{Sample outlier analysis}
\usage{
outlier_analysis(x, criterion = c("30_percent", "2_sd", "chauvenet"))
}
\arguments{
\item{x}{a vector of class numeric.}
\item{criter... | /man/outlier_analysis.Rd | permissive | lfpdroubi/appraiseR | R | false | true | 621 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/outlier_analysis.R
\name{outlier_analysis}
\alias{outlier_analysis}
\title{Sample outlier analysis}
\usage{
outlier_analysis(x, criterion = c("30_percent", "2_sd", "chauvenet"))
}
\arguments{
\item{x}{a vector of class numeric.}
\item{criter... |
require(data.table)
pd <- fread("household_power_consumption.txt")
pd$Date <- as.Date(pd$Date, "%d/%m/%Y")
pd<-subset(pd, Date >= as.Date("2/1/2007","%m/%d/%Y") & Date <= as.Date("2/2/2007","%m/%d/%Y"), select = (1:9))
pd$Global_active_power <- as.numeric(pd$Global_active_power)
pd$Sub_metering_1 <- as.numeric(pd$Su... | /plot4.R | no_license | cmwieneke/ExData_Plotting1 | R | false | false | 1,395 | r | require(data.table)
pd <- fread("household_power_consumption.txt")
pd$Date <- as.Date(pd$Date, "%d/%m/%Y")
pd<-subset(pd, Date >= as.Date("2/1/2007","%m/%d/%Y") & Date <= as.Date("2/2/2007","%m/%d/%Y"), select = (1:9))
pd$Global_active_power <- as.numeric(pd$Global_active_power)
pd$Sub_metering_1 <- as.numeric(pd$Su... |
/code/dstatR2code.R | no_license | jdwbh/dstatR | R | false | false | 35,393 | r | ||
# This is to check that my solutions to model1's ODEs are correct
# 10 Oct 2011
# E(N(t)) is expected number of individuals left in the stream
# V(t) is the variance in the number left
# ODEs for dE(N)/dt and dV/dt:
# dE(N)/dt = f(E(N))
# dV/dt = -2f'(N)V + f(N)
# from Carl Boettiger
# model1 and my analytical solut... | /simulation of model1 v(t).R | no_license | wcwetzel/Invert-drift-modeling | R | false | false | 1,451 | r | # This is to check that my solutions to model1's ODEs are correct
# 10 Oct 2011
# E(N(t)) is expected number of individuals left in the stream
# V(t) is the variance in the number left
# ODEs for dE(N)/dt and dV/dt:
# dE(N)/dt = f(E(N))
# dV/dt = -2f'(N)V + f(N)
# from Carl Boettiger
# model1 and my analytical solut... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/androidpublisher_objects.R
\name{Listing}
\alias{Listing}
\title{Listing Object}
\usage{
Listing(fullDescription = NULL, language = NULL, shortDescription = NULL,
title = NULL, video = NULL)
}
\arguments{
\item{fullDescription}{Full descrip... | /googleandroidpublisherv2.auto/man/Listing.Rd | permissive | Phippsy/autoGoogleAPI | R | false | true | 854 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/androidpublisher_objects.R
\name{Listing}
\alias{Listing}
\title{Listing Object}
\usage{
Listing(fullDescription = NULL, language = NULL, shortDescription = NULL,
title = NULL, video = NULL)
}
\arguments{
\item{fullDescription}{Full descrip... |
% Generated by roxygen2 (4.0.2): do not edit by hand
\name{sju.strpos}
\alias{sju.strpos}
\title{Find partial matching and close distance elements in strings}
\usage{
sju.strpos(searchString, findTerm, maxdist = 3, part.dist.match = 0,
showProgressBar = FALSE)
}
\arguments{
\item{searchString}{a character vector with... | /man/sju.strpos.Rd | no_license | wilpi/devel | R | false | false | 2,668 | rd | % Generated by roxygen2 (4.0.2): do not edit by hand
\name{sju.strpos}
\alias{sju.strpos}
\title{Find partial matching and close distance elements in strings}
\usage{
sju.strpos(searchString, findTerm, maxdist = 3, part.dist.match = 0,
showProgressBar = FALSE)
}
\arguments{
\item{searchString}{a character vector with... |
library(rDrop)
source("getCred.R")
if(!is.null(drop <- getCred()))
{
a = 1:10
b = pi
c = LETTERS
d = rnorm
dropbox_save(drop, a, b, c, d, file = "rDropTest")
rm(a, b, c, d)
dropbox_load(drop, "rDropTest.rda")
}
| /tests/dropbox_save.R | no_license | karthik/rDrop | R | false | false | 232 | r | library(rDrop)
source("getCred.R")
if(!is.null(drop <- getCred()))
{
a = 1:10
b = pi
c = LETTERS
d = rnorm
dropbox_save(drop, a, b, c, d, file = "rDropTest")
rm(a, b, c, d)
dropbox_load(drop, "rDropTest.rda")
}
|
rm(list=ls());gc()
library(caret)
library(xgboost)
library(quantmod)
library(vars)
source('tests/AutomatedSystems/IBPaperTradingIndicators.R')
Sys.setenv(TZ='US/Eastern')
AUDUSD = prepareForexData(ib.duration = "8 Y", ib.barsize = "1 day", Cur1 = "AUD", Cur2 = "USD",
oanda.granularity = 'D', ... | /tests/old/FactorAnalysis.R | permissive | elephann/RQuantTrader | R | false | false | 2,094 | r | rm(list=ls());gc()
library(caret)
library(xgboost)
library(quantmod)
library(vars)
source('tests/AutomatedSystems/IBPaperTradingIndicators.R')
Sys.setenv(TZ='US/Eastern')
AUDUSD = prepareForexData(ib.duration = "8 Y", ib.barsize = "1 day", Cur1 = "AUD", Cur2 = "USD",
oanda.granularity = 'D', ... |
####################################################################
# Name: PCA_Humichip_V145_AbxRes_AZI.R
# Author: Ryan Johnson
# Date Created: 4 Sep 2019
# Purpose: Perform PCA on Humichip Data, visit 1-4-5 samples, color
# by visit. Only consider patients in AZI group. Only use Abx
# Res probes
###############... | /code/Manuscript_code/PCA_Humichip_V145_AbxRes_AZI.R | no_license | ryjohnson09/HumiChip | R | false | false | 4,528 | r | ####################################################################
# Name: PCA_Humichip_V145_AbxRes_AZI.R
# Author: Ryan Johnson
# Date Created: 4 Sep 2019
# Purpose: Perform PCA on Humichip Data, visit 1-4-5 samples, color
# by visit. Only consider patients in AZI group. Only use Abx
# Res probes
###############... |
TeO.full <- read.dta13(paste(path.data,"TeO_full_post_fuzzy_clustering_051920.dta",sep=""), convert.factors = FALSE) %>% as_tibble()
## Create the dependent variable - a linear addition of r_food and r_impvie
TeO.full <- TeO.full %>% mutate(s_rel=r_food+r_impvie) %>% filter(native==0 | native==1 | native==-1) %>% as.... | /7_profile_analysis_r_impvie.R | no_license | ldrouhot/Drouhot_cracks_paper_AJS_2021 | R | false | false | 11,109 | r | TeO.full <- read.dta13(paste(path.data,"TeO_full_post_fuzzy_clustering_051920.dta",sep=""), convert.factors = FALSE) %>% as_tibble()
## Create the dependent variable - a linear addition of r_food and r_impvie
TeO.full <- TeO.full %>% mutate(s_rel=r_food+r_impvie) %>% filter(native==0 | native==1 | native==-1) %>% as.... |
context("Evaluating speciesSummary() calcuations")
suppressWarnings(library(dplyr))
suppressWarnings(library(tidyr))
data(testdb)
bluebird_summary_order = speciesSummary("Bluebird", by = "Order", db = testdb)
test_that("Calculating mean fraction diet across studies, any season", {
expect_equal(bluebird_summary_or... | /tests/testthat/test_speciesSummary.r | no_license | jmb004/aviandietdb | R | false | false | 857 | r | context("Evaluating speciesSummary() calcuations")
suppressWarnings(library(dplyr))
suppressWarnings(library(tidyr))
data(testdb)
bluebird_summary_order = speciesSummary("Bluebird", by = "Order", db = testdb)
test_that("Calculating mean fraction diet across studies, any season", {
expect_equal(bluebird_summary_or... |
# Ejemplo 3. Variantes en la lectura de BDD con R
# Ahora utilizaremos otra opción para realizar queries a una BDD con la ayuda
# de dplyr que sustituye a SELECT en MySQL y el operador %>%, hay que recordar
# que con este comando también podemos realizar búsquedas de forma local.
# Comenzamos instalando las paquete... | /R/Sesion_7/Ejemplo7_03.R | no_license | panchis7u7/Statistics_with_R | R | false | false | 1,519 | r | # Ejemplo 3. Variantes en la lectura de BDD con R
# Ahora utilizaremos otra opción para realizar queries a una BDD con la ayuda
# de dplyr que sustituye a SELECT en MySQL y el operador %>%, hay que recordar
# que con este comando también podemos realizar búsquedas de forma local.
# Comenzamos instalando las paquete... |
# Use a generalized linear model to find a decay rate directly from the observed
# data, without using our model.
# The details of this analysis:
# - "standard" integration data
# - special handling for P3's VL data (i.e. model starts from the
# blip rather than ART initiation) and integration dates
# - duplicat... | /EliteControllers/model_free_decay_rates.r | no_license | cfe-lab/ReservoirModelling | R | false | false | 1,574 | r | # Use a generalized linear model to find a decay rate directly from the observed
# data, without using our model.
# The details of this analysis:
# - "standard" integration data
# - special handling for P3's VL data (i.e. model starts from the
# blip rather than ART initiation) and integration dates
# - duplicat... |
symbolTableClass <-
R6::R6Class(
classname = 'symbolTableClass',
portable = FALSE,
private = list(
deep_clone = function(name, value) {
switch(name,
symbols = {
ans <- lapply(value,
function(x) x$clone(deep = TRUE)
... | /nCompiler/R/symbolTableClass.R | permissive | nimble-dev/nCompiler | R | false | false | 4,471 | r | symbolTableClass <-
R6::R6Class(
classname = 'symbolTableClass',
portable = FALSE,
private = list(
deep_clone = function(name, value) {
switch(name,
symbols = {
ans <- lapply(value,
function(x) x$clone(deep = TRUE)
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/example_data.R
\docType{data}
\name{example_data}
\alias{example_data}
\alias{reg_res_svm}
\alias{reg_res_sp}
\alias{reg_res_lr}
\alias{reg_folds}
\alias{class_res_nn}
\alias{class_res_rf}
\alias{class_folds}
\alias{log_res_nn}
\alias{log_res... | /man/example_data.Rd | permissive | YX577/stacks | R | false | true | 9,886 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/example_data.R
\docType{data}
\name{example_data}
\alias{example_data}
\alias{reg_res_svm}
\alias{reg_res_sp}
\alias{reg_res_lr}
\alias{reg_folds}
\alias{class_res_nn}
\alias{class_res_rf}
\alias{class_folds}
\alias{log_res_nn}
\alias{log_res... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{is_natural_number}
\alias{is_natural_number}
\title{Test for Natural Numbers}
\usage{
is_natural_number(x)
}
\arguments{
\item{x}{\code{numeric} vector}
}
\value{
\code{TRUE} in case \code{x} is a natural number,
\code{FALSE} ... | /man/is_natural_number.Rd | no_license | cran/litteR | R | false | true | 641 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{is_natural_number}
\alias{is_natural_number}
\title{Test for Natural Numbers}
\usage{
is_natural_number(x)
}
\arguments{
\item{x}{\code{numeric} vector}
}
\value{
\code{TRUE} in case \code{x} is a natural number,
\code{FALSE} ... |
# Burak Himmetoglu
# 10-11-2017
# bhimmetoglu@ucsb.edu
#
# Titanic Survival Prediction -- Basic Modeling
#
# Libraries
library(glmnet)
library(doMC)
registerDoMC() # For parallel processing, you can add number of cores
# Clean and prepare data
source('clean_data.R')
# Let us remove PassangerId as a predictor
train <-... | /CSC-Computing-2017-master/R/titanic/linearModel.R | no_license | UCSBMRL/Center-for-Scientific-Computing | R | false | false | 2,364 | r | # Burak Himmetoglu
# 10-11-2017
# bhimmetoglu@ucsb.edu
#
# Titanic Survival Prediction -- Basic Modeling
#
# Libraries
library(glmnet)
library(doMC)
registerDoMC() # For parallel processing, you can add number of cores
# Clean and prepare data
source('clean_data.R')
# Let us remove PassangerId as a predictor
train <-... |
## The following function performs 4 tasks: set matrix, get matrix, set Inverse of the matrix and get its inverse.
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
setinverse <- function... | /cachematrix.R | no_license | shgorkhali/ProgrammingAssignment2 | R | false | false | 951 | r | ## The following function performs 4 tasks: set matrix, get matrix, set Inverse of the matrix and get its inverse.
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
setinverse <- function... |
library(UnitTestPackage)
context("String reverser")
test_that("Strings are reversed correctly",{
expect_equal(reverser("try"),"yrt")
expect_equal(reverser("with gap"),"pag htiw")
expect_equal(reverser("a"),"a")
})
| /tests/testthat/test_reverser.R | no_license | pkchouhan14/UnitTestPackage | R | false | false | 224 | r | library(UnitTestPackage)
context("String reverser")
test_that("Strings are reversed correctly",{
expect_equal(reverser("try"),"yrt")
expect_equal(reverser("with gap"),"pag htiw")
expect_equal(reverser("a"),"a")
})
|
#' Maximum Sensitivity (True Positive Rate) plotting
#'
#' This function allows to use a custom thresholding method to maximize the Sensitivity (True Positive Rate). A data.table of values is returned.
#'
#' @param preds Type: numeric. The predictions.
#' @param labels Type: numeric. The labels (0, 1).
#' @param plot... | /R/plot.max_sensitivity.R | no_license | BruceZhaoR/Laurae | R | false | false | 1,111 | r | #' Maximum Sensitivity (True Positive Rate) plotting
#'
#' This function allows to use a custom thresholding method to maximize the Sensitivity (True Positive Rate). A data.table of values is returned.
#'
#' @param preds Type: numeric. The predictions.
#' @param labels Type: numeric. The labels (0, 1).
#' @param plot... |
context("CMT")
library(psychTestR)
app <- AppTester$new("apps/CMT_de_subscales_(Re)productive_competence")
app$expect_ui_text("Bitte gib Deine ID ein Weiter")
app$set_inputs(p_id = "abcde")
app$click_next()
app$expect_ui_text("In diesem Fragebogen geht es um Deinen Musikunterricht in der Schule. Du wirst nach versch... | /tests/testthat/test-CMT_de_subscales_(Re)productive_competence.R | permissive | fmhoeger/psyquest | R | false | false | 1,973 | r | context("CMT")
library(psychTestR)
app <- AppTester$new("apps/CMT_de_subscales_(Re)productive_competence")
app$expect_ui_text("Bitte gib Deine ID ein Weiter")
app$set_inputs(p_id = "abcde")
app$click_next()
app$expect_ui_text("In diesem Fragebogen geht es um Deinen Musikunterricht in der Schule. Du wirst nach versch... |
\name{trQuantMLE}
\alias{trQuantMLE}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Estimator of large quantiles using truncated MLE
}
\description{
This function computes estimates of large quantiles \eqn{Q(1-p)} of the truncated distribution using the ML estimates adapted for upper truncation.... | /man/trQuantMLE.Rd | no_license | kevinykuo/ReIns | R | false | false | 3,692 | rd | \name{trQuantMLE}
\alias{trQuantMLE}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Estimator of large quantiles using truncated MLE
}
\description{
This function computes estimates of large quantiles \eqn{Q(1-p)} of the truncated distribution using the ML estimates adapted for upper truncation.... |
download.file("https://d396qusza40orc.cloudfront.net/getdata%2Fdata%2Fss06hid.csv ","acs.csv")
data <- read.csv("acs.csv")
values <- data$VAL
values <- values[!is.na(values)]
above1M <- sum(values == as.integer(24),na.rm=TRUE)
print(above1M)
library(xlsx)
colIndex <- 7:15
rowIndex <- 18:23
dat <- read.xlsx("getdata-da... | /gettingdata/getdatawk1.R | no_license | scsmith2/coursera | R | false | false | 1,135 | r | download.file("https://d396qusza40orc.cloudfront.net/getdata%2Fdata%2Fss06hid.csv ","acs.csv")
data <- read.csv("acs.csv")
values <- data$VAL
values <- values[!is.na(values)]
above1M <- sum(values == as.integer(24),na.rm=TRUE)
print(above1M)
library(xlsx)
colIndex <- 7:15
rowIndex <- 18:23
dat <- read.xlsx("getdata-da... |
library(SensoMineR)
### Name: indscal
### Title: Construct the Indscal model for Napping data type
### Aliases: indscal
### Keywords: multivariate
### ** Examples
## Not run:
##D data(napping)
##D nappeplot(napping.don)
##D resindscal<- indscal(napping.don, napping.words)
##D dev.new()
##D prefpls(cbind(resindscal... | /data/genthat_extracted_code/SensoMineR/examples/indscal.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 446 | r | library(SensoMineR)
### Name: indscal
### Title: Construct the Indscal model for Napping data type
### Aliases: indscal
### Keywords: multivariate
### ** Examples
## Not run:
##D data(napping)
##D nappeplot(napping.don)
##D resindscal<- indscal(napping.don, napping.words)
##D dev.new()
##D prefpls(cbind(resindscal... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/content_objects.R
\name{AccountsCustomBatchRequestEntry}
\alias{AccountsCustomBatchRequestEntry}
\title{AccountsCustomBatchRequestEntry Object}
\usage{
AccountsCustomBatchRequestEntry(account = NULL, accountId = NULL,
batchId = NULL, mercha... | /googlecontentv2.auto/man/AccountsCustomBatchRequestEntry.Rd | permissive | GVersteeg/autoGoogleAPI | R | false | true | 858 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/content_objects.R
\name{AccountsCustomBatchRequestEntry}
\alias{AccountsCustomBatchRequestEntry}
\title{AccountsCustomBatchRequestEntry Object}
\usage{
AccountsCustomBatchRequestEntry(account = NULL, accountId = NULL,
batchId = NULL, mercha... |
# function to test both non-inferiority and superiority:
to_test <- function(data, treatment.seq, placebo.seq, indi.shared.dist, indi.noninf.equiv, N, g.treat, g.placebo,
theta, z_alpha){
# indi.shared.dist: "Sh" for shared and "Di" for distint path
# indi.noninf.equiv: "... | /Data_Analysis_R_Code/test_power_data_analysis.r | no_license | palashghosh1/Simulation_Non_Inferiority_Equivalence_SMART | R | false | false | 6,671 | r |
# function to test both non-inferiority and superiority:
to_test <- function(data, treatment.seq, placebo.seq, indi.shared.dist, indi.noninf.equiv, N, g.treat, g.placebo,
theta, z_alpha){
# indi.shared.dist: "Sh" for shared and "Di" for distint path
# indi.noninf.equiv: "... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ps.cluster.R
\name{ps.cluster}
\alias{ps.cluster}
\title{Function to compute the prediction strength of a clustering model}
\usage{
ps.cluster(cl.tr, cl.ts, na.rm = FALSE)
}
\arguments{
\item{cl.tr}{Clusters membership as defined by the origi... | /man/ps.cluster.Rd | no_license | bhklab/genefu | R | false | true | 1,848 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ps.cluster.R
\name{ps.cluster}
\alias{ps.cluster}
\title{Function to compute the prediction strength of a clustering model}
\usage{
ps.cluster(cl.tr, cl.ts, na.rm = FALSE)
}
\arguments{
\item{cl.tr}{Clusters membership as defined by the origi... |
#' @title testr: Bayesian A/B Testing Engine
#' @description Tools for Bayesian design and analysis of of randomized
#' experiments (A/B/../N tests). testr uses an adaptive design (i.e.
#' early stopping rules), allowing tests to end as early as possible.
#' @name testr
#' @docType package
NULL
| /R/testr-package.r | permissive | isabella232/testr | R | false | false | 300 | r | #' @title testr: Bayesian A/B Testing Engine
#' @description Tools for Bayesian design and analysis of of randomized
#' experiments (A/B/../N tests). testr uses an adaptive design (i.e.
#' early stopping rules), allowing tests to end as early as possible.
#' @name testr
#' @docType package
NULL
|
word <- "MoreCodes"
strLength <- nchar(word)
print(paste("String Length: ", strLength))
| /Easy Problems/problem13.r | no_license | ArjunAranetaCodes/MoreCodes-Rlang | R | false | false | 90 | r |
word <- "MoreCodes"
strLength <- nchar(word)
print(paste("String Length: ", strLength))
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/dmbc_classes.R
\name{plot,dmbc_fit_list,ANY-method}
\alias{plot,dmbc_fit_list,ANY-method}
\alias{plot,dmbc_fit_list-method}
\alias{dmbc_fit_list-plot}
\title{Provide a graphical summary of a \code{dmbc_fit_list} class instance.}
\usage{
\S4me... | /fuzzedpackages/dmbc/man/plot-dmbc_fit_list-ANY-method.Rd | no_license | akhikolla/testpackages | R | false | true | 1,906 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/dmbc_classes.R
\name{plot,dmbc_fit_list,ANY-method}
\alias{plot,dmbc_fit_list,ANY-method}
\alias{plot,dmbc_fit_list-method}
\alias{dmbc_fit_list-plot}
\title{Provide a graphical summary of a \code{dmbc_fit_list} class instance.}
\usage{
\S4me... |
levels(Clean_trainData[,"race"]) <- union(levels(test[,"race"]),levels(Clean_trainData[,"race"]))
levels(Clean_trainData[,"sex"]) <- union(levels(test[,"sex"]),levels(Clean_trainData[,"sex"]))
levels(Clean_trainData[,"nativecountry"]) <- union(levels(test[,"nativecountry"]),levels(Clean_trainData[,"nativecountry"]))
... | /milestone4.r | no_license | mbhavana/Census-income-prediction | R | false | false | 5,804 | r | levels(Clean_trainData[,"race"]) <- union(levels(test[,"race"]),levels(Clean_trainData[,"race"]))
levels(Clean_trainData[,"sex"]) <- union(levels(test[,"sex"]),levels(Clean_trainData[,"sex"]))
levels(Clean_trainData[,"nativecountry"]) <- union(levels(test[,"nativecountry"]),levels(Clean_trainData[,"nativecountry"]))
... |
# Created from the function of Giampierro Marra
VC.test <- function (obj1, obj2, sig.lev = 0.05)
{
# check for gamlss models
if (!is.gamlss(obj1)) stop(paste("Object 1 is not a gamlss object", "\n", ""))
if (!is.gamlss(obj2)) stop(paste("Object 2 is not a gamlss object", "\n", ""))
# get the likelihood func... | /R/VuongClarkTest.R | no_license | sunfeng98/GAMLSS-original | R | false | false | 5,075 | r | # Created from the function of Giampierro Marra
VC.test <- function (obj1, obj2, sig.lev = 0.05)
{
# check for gamlss models
if (!is.gamlss(obj1)) stop(paste("Object 1 is not a gamlss object", "\n", ""))
if (!is.gamlss(obj2)) stop(paste("Object 2 is not a gamlss object", "\n", ""))
# get the likelihood func... |
uu<-seq(0,1,length=100)
uu<-uu[c(-1,-100)]
z_scores <- qnorm(uu)
pvalues <- pnorm(z_scores)
plot(z_scores,pvalues,type="l",
xlab="Quantiles",
ylab = "Probability",
xaxt="n",
main = "CDF")
axis(1,at=which(pvalues == pnorm(qnorm(0.2)),
labels=round(qnorm(0.2),2))
axis(1,at=which(pvalues == pno... | /week9-2.R | no_license | Keine199794/Myproject | R | false | false | 453 | r | uu<-seq(0,1,length=100)
uu<-uu[c(-1,-100)]
z_scores <- qnorm(uu)
pvalues <- pnorm(z_scores)
plot(z_scores,pvalues,type="l",
xlab="Quantiles",
ylab = "Probability",
xaxt="n",
main = "CDF")
axis(1,at=which(pvalues == pnorm(qnorm(0.2)),
labels=round(qnorm(0.2),2))
axis(1,at=which(pvalues == pno... |
#Download the data set as german_credit,stringsasfactors is kept as false as we dont want strings to be
#considered as factors or categorical data.
german_credit<-read.csv("german.csv",stringsAsFactors = F)
#install the required packages.
#install.packages("car")
#install.packages("Hmisc")
#install.packages("... | /Predict a loan Defaulter(Logistic Regression)/Loan_defaulter_logisticRegression.R | no_license | anand-sonawane/Predictive-Analytics | R | false | false | 26,278 | r | #Download the data set as german_credit,stringsasfactors is kept as false as we dont want strings to be
#considered as factors or categorical data.
german_credit<-read.csv("german.csv",stringsAsFactors = F)
#install the required packages.
#install.packages("car")
#install.packages("Hmisc")
#install.packages("... |
## Below are two functions that are used to create a special object
## that stores a matrix and cache's the inverse of the matrix.
## This function creates a special matrix object that can cache its inverse.
makeCacheMatrix <- function(x = matrix()) {
i <- NULL
set <- function(y) {
x <... | /cachematrix.R | no_license | Olga0424/ProgrammingAssignment2 | R | false | false | 1,256 | r | ## Below are two functions that are used to create a special object
## that stores a matrix and cache's the inverse of the matrix.
## This function creates a special matrix object that can cache its inverse.
makeCacheMatrix <- function(x = matrix()) {
i <- NULL
set <- function(y) {
x <... |
##Loading Packages
library(dplyr)
library(amt)
library(shiny)
library(htmlwidgets)
library(htmltools)
library(leaflet)
library(geojsonio)
library(sf)
library(leafletCN)
library(ggplot2)
library(ggrepel)
library(plotly)
library(knitr)
library(kableExtra)
library(viridis)
##Sourcing Function... | /app.r | no_license | amgeronimo/COVID19-HHH4-Africa | R | false | false | 14,775 | r |
##Loading Packages
library(dplyr)
library(amt)
library(shiny)
library(htmlwidgets)
library(htmltools)
library(leaflet)
library(geojsonio)
library(sf)
library(leafletCN)
library(ggplot2)
library(ggrepel)
library(plotly)
library(knitr)
library(kableExtra)
library(viridis)
##Sourcing Function... |
#' @title Two Sample Test of Proportion
#' @description Tests on the equality of proportions using
#' large-sample statistics. It tests that a sample has the same proportion
#' within two independent groups or two samples have the same proportion.
#' @param data a \code{data.frame} or \code{tibble}
#' @param var1 ... | /R/ifr-ts-prop-test.R | no_license | cran/inferr | R | false | false | 6,787 | r | #' @title Two Sample Test of Proportion
#' @description Tests on the equality of proportions using
#' large-sample statistics. It tests that a sample has the same proportion
#' within two independent groups or two samples have the same proportion.
#' @param data a \code{data.frame} or \code{tibble}
#' @param var1 ... |
library(ggplot2)
library(dplyr)
library(magrittr)
library(grid)
library(gtable)
library(reshape)
library(RColorBrewer)
setwd("~/Desktop/allSites_50kb/ratios")
getList <- function(file_name_pattern, ...) {
file_list_vector <- list.files(pattern = "prop") # makes a list of all files with the ending ".pestPG" which is... | /RScriptB2.R | no_license | CMWthesis/eAppendix-R | R | false | false | 12,726 | r | library(ggplot2)
library(dplyr)
library(magrittr)
library(grid)
library(gtable)
library(reshape)
library(RColorBrewer)
setwd("~/Desktop/allSites_50kb/ratios")
getList <- function(file_name_pattern, ...) {
file_list_vector <- list.files(pattern = "prop") # makes a list of all files with the ending ".pestPG" which is... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/codec-device-raster.R
\name{decode_device_raster_to_robj}
\alias{decode_device_raster_to_robj}
\title{Extract a R object encoded in a device-raster}
\usage{
decode_device_raster_to_robj(device_raster)
}
\arguments{
\item{device_raster}{a rast... | /man/decode_device_raster_to_robj.Rd | permissive | coolbutuseless/snowcrash | R | false | true | 587 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/codec-device-raster.R
\name{decode_device_raster_to_robj}
\alias{decode_device_raster_to_robj}
\title{Extract a R object encoded in a device-raster}
\usage{
decode_device_raster_to_robj(device_raster)
}
\arguments{
\item{device_raster}{a rast... |
# Script to create climate summaries given output from climate BC
##Kiri Daust, April 2020
######Future Data#################################
library(foreach)
library(data.table)
library(matrixStats)
library(tidyr)
betterMods <- c("CanESM2", "CCSM4", "CESM1-CAM5", "CSIRO-Mk3.6.0", "GISS-E2R", "HadGEM2-ES", "MIROC5", ... | /Climate_Summaries.R | no_license | FLNRO-Smithers-Research/BGC-Climate-Summaries | R | false | false | 6,215 | r | # Script to create climate summaries given output from climate BC
##Kiri Daust, April 2020
######Future Data#################################
library(foreach)
library(data.table)
library(matrixStats)
library(tidyr)
betterMods <- c("CanESM2", "CCSM4", "CESM1-CAM5", "CSIRO-Mk3.6.0", "GISS-E2R", "HadGEM2-ES", "MIROC5", ... |
library(tidyverse)
terremotos_modelo_intensidad <- readRDS(file = "02_Data_preparation/01_Clean_data/terremotos_clean_modelo_intensidad.rds")
my_data <- readRDS("data/mapa_ESP.rds")
unique(terremotos_modelo_intensidad$inten)
terremotos_modelo_intensidad <- terremotos_modelo_intensidad %>%
dplyr::mutate(inten = repl... | /02_Data_preparation/02_Construct_data/01_Construct_terremotos_modelo_intensidad.R | no_license | TFM-2021/TFM-2021 | R | false | false | 1,846 | r | library(tidyverse)
terremotos_modelo_intensidad <- readRDS(file = "02_Data_preparation/01_Clean_data/terremotos_clean_modelo_intensidad.rds")
my_data <- readRDS("data/mapa_ESP.rds")
unique(terremotos_modelo_intensidad$inten)
terremotos_modelo_intensidad <- terremotos_modelo_intensidad %>%
dplyr::mutate(inten = repl... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/powrballad-package.r
\docType{data}
\name{ballads}
\alias{ballads}
\title{A list of Power Ballads that can be used to randomly select from}
\format{An object of class \code{data.frame} with 38 rows and 1 columns.}
\usage{
ballads
}
\descripti... | /man/ballads.Rd | permissive | Raoke/powrballad | R | false | true | 410 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/powrballad-package.r
\docType{data}
\name{ballads}
\alias{ballads}
\title{A list of Power Ballads that can be used to randomly select from}
\format{An object of class \code{data.frame} with 38 rows and 1 columns.}
\usage{
ballads
}
\descripti... |
sensex_data <- read.csv("BSE_Sensex_Index.csv")
View(sensex_data)
growth_rate <- c()
for(i in 1:15446){
growth_rate[i] <- (sensex_data$Close[i] - sensex_data$Close[i+1])/sensex_data$Close[i+1]
}
growth_rate[15447]<- (growth_rate[15446] +growth_rate[15445]+growth_rate[15444])/3
growth_rate[15447]
z_gro... | /Data Mining/Data Mining Assignments/Exam Solutions/8question.R | no_license | aleemsameer/DataScience_2019501059 | R | false | false | 830 | r | sensex_data <- read.csv("BSE_Sensex_Index.csv")
View(sensex_data)
growth_rate <- c()
for(i in 1:15446){
growth_rate[i] <- (sensex_data$Close[i] - sensex_data$Close[i+1])/sensex_data$Close[i+1]
}
growth_rate[15447]<- (growth_rate[15446] +growth_rate[15445]+growth_rate[15444])/3
growth_rate[15447]
z_gro... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/nhsid.R
\name{gen_nhsid}
\alias{gen_nhsid}
\title{Generate a random nhsid.}
\usage{
gen_nhsid()
}
\value{
The output is string with 10 numbers.
}
\description{
\code{gen_nhsid} randomly return a 10-digit nhsid that is generated
following ... | /man/gen_nhsid.Rd | no_license | cran/sdglinkage | R | false | true | 374 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/nhsid.R
\name{gen_nhsid}
\alias{gen_nhsid}
\title{Generate a random nhsid.}
\usage{
gen_nhsid()
}
\value{
The output is string with 10 numbers.
}
\description{
\code{gen_nhsid} randomly return a 10-digit nhsid that is generated
following ... |
#
# This is a Shiny web application. You can run the application by clicking
# the 'Run App' button above.
#
# Find out more about building applications with Shiny here:
#
# http://shiny.rstudio.com/
#
library(RSQLite)
library(DBI)
library(shiny)
library(tidyverse)
library(GeomMLBStadiums)
#install.pa... | /Shiny Dashboard Basics - Building a Shiny App Part 3/app.R | permissive | robert-frey/YouTube | R | false | false | 2,006 | r | #
# This is a Shiny web application. You can run the application by clicking
# the 'Run App' button above.
#
# Find out more about building applications with Shiny here:
#
# http://shiny.rstudio.com/
#
library(RSQLite)
library(DBI)
library(shiny)
library(tidyverse)
library(GeomMLBStadiums)
#install.pa... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/RcppExports.R
\name{SRMPLE}
\alias{SRMPLE}
\title{Non_monotone proximal gradient algorithm}
\usage{
SRMPLE(X,de,Z,betaini,k,tol=1e-3,maxiter=50)
}
\arguments{
\item{X}{a vector of observed time for the population}
\item{de}{a vector of censo... | /man/SRMPLE.Rd | no_license | iantsuising/coxnpgsjs | R | false | true | 1,597 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/RcppExports.R
\name{SRMPLE}
\alias{SRMPLE}
\title{Non_monotone proximal gradient algorithm}
\usage{
SRMPLE(X,de,Z,betaini,k,tol=1e-3,maxiter=50)
}
\arguments{
\item{X}{a vector of observed time for the population}
\item{de}{a vector of censo... |
% Generated by roxygen2 (4.0.2): do not edit by hand
\docType{data}
\name{mongo.bson.code}
\alias{mongo.bson.code}
\title{BSON data type constant for a code value}
\format{\preformatted{ int 13
}}
\usage{
mongo.bson.code
}
\value{
13L
}
\description{
\code{\link{mongo.bson.iterator.type}()} and
\code{\link{mongo.bson.i... | /man/mongo.bson.code.Rd | no_license | agnaldodasilva/rmongodb | R | false | false | 581 | rd | % Generated by roxygen2 (4.0.2): do not edit by hand
\docType{data}
\name{mongo.bson.code}
\alias{mongo.bson.code}
\title{BSON data type constant for a code value}
\format{\preformatted{ int 13
}}
\usage{
mongo.bson.code
}
\value{
13L
}
\description{
\code{\link{mongo.bson.iterator.type}()} and
\code{\link{mongo.bson.i... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/candidate_functions.r
\name{factorprop}
\alias{factorprop}
\title{factorprop summarizes the properties of a potential factor}
\usage{
factorprop(
indat,
fact,
resdir,
runname,
year = "year",
catch = "catch",
effort = "hours",
... | /man/factorprop.Rd | permissive | habeebollah/rforcpue | R | false | true | 1,823 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/candidate_functions.r
\name{factorprop}
\alias{factorprop}
\title{factorprop summarizes the properties of a potential factor}
\usage{
factorprop(
indat,
fact,
resdir,
runname,
year = "year",
catch = "catch",
effort = "hours",
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{df_to_iso}
\alias{df_to_iso}
\title{Function to convert a data frame with x, y, z variables into an isoline or isoband object}
\usage{
df_to_iso(
df,
levs,
levs_high = NULL,
x = "X",
y = "Y",
z = "sdf",
buffer = NU... | /man/df_to_iso.Rd | permissive | rdinnager/rngnet | R | false | true | 469 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{df_to_iso}
\alias{df_to_iso}
\title{Function to convert a data frame with x, y, z variables into an isoline or isoband object}
\usage{
df_to_iso(
df,
levs,
levs_high = NULL,
x = "X",
y = "Y",
z = "sdf",
buffer = NU... |
# Initialize ---------------------------
# Load libraries
library(platexpress)
library(reshape2)
library(pracma)
library(ggplot2)
library(mugro)
library(growthrates)
library(pspline)
library(tidyr)
library(data.table)
library(plyr)
# Define analyzed study
study_id <- "SDY007"
study_sub <- NA
# Define used drymass es... | /02_data_analysis/20210110_analysis_SDY007_HighA.R | no_license | pfennigt/e_coli_growth | R | false | false | 13,725 | r | # Initialize ---------------------------
# Load libraries
library(platexpress)
library(reshape2)
library(pracma)
library(ggplot2)
library(mugro)
library(growthrates)
library(pspline)
library(tidyr)
library(data.table)
library(plyr)
# Define analyzed study
study_id <- "SDY007"
study_sub <- NA
# Define used drymass es... |
# ODE model
model <- function(t, x, parms) {
with(as.list(parms),{
dx <- numeric()
# 1: S_low
# 2: S_high
# 3: I_Sen_low
# 4: I_Sen_high
# 5: I_Res_low
# 6: I_Res_high
# 7: W_low
# 8: W_high
# prevalences
dx[1] <-
(
- x[1]*pic[1]*sum(rho[1,]*beta[1,]... | /scripts/f_model.R | permissive | calthaus/NG-POC-resistance | R | false | false | 4,321 | r | # ODE model
model <- function(t, x, parms) {
with(as.list(parms),{
dx <- numeric()
# 1: S_low
# 2: S_high
# 3: I_Sen_low
# 4: I_Sen_high
# 5: I_Res_low
# 6: I_Res_high
# 7: W_low
# 8: W_high
# prevalences
dx[1] <-
(
- x[1]*pic[1]*sum(rho[1,]*beta[1,]... |
#' Cumulative distribution function of Pearson type-3 Distribution
#'
#' @param x quantile/s
#' @param para parameters as c(mu, sigma, gamma) that are c(location, scale, shape).
#'
#' @return Non-exceedance probability from the cumulative distribution function.
#' @author Mohanad Zaghloul [aut, cre], Simon Michae... | /R/ppe3.R | no_license | cran/LMoFit | R | false | false | 572 | r | #' Cumulative distribution function of Pearson type-3 Distribution
#'
#' @param x quantile/s
#' @param para parameters as c(mu, sigma, gamma) that are c(location, scale, shape).
#'
#' @return Non-exceedance probability from the cumulative distribution function.
#' @author Mohanad Zaghloul [aut, cre], Simon Michae... |
# startingValues: Find starting values of free parameters based on pre-specified starting values. If the pre-specified starting values are numbers, the function will use that values. If they
# are distribution object, this function will randomly draw from the distribution 10 times and take the average of those values.... | /simsem/R/startingValues-methods.R | no_license | pairach/simsem | R | false | false | 1,571 | r | # startingValues: Find starting values of free parameters based on pre-specified starting values. If the pre-specified starting values are numbers, the function will use that values. If they
# are distribution object, this function will randomly draw from the distribution 10 times and take the average of those values.... |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do not modify this file since it was automatically generated from:
%
% RspDirective.R
%
% by the Rdoc compiler part of the R.oo package.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\name{getType.RspPageDirect... | /man/getType.RspPageDirective.Rd | no_license | HenrikBengtsson/R.rsp | R | false | false | 907 | rd | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do not modify this file since it was automatically generated from:
%
% RspDirective.R
%
% by the Rdoc compiler part of the R.oo package.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\name{getType.RspPageDirect... |
/q2.R | no_license | DatenBiene/Time_Series-Production_Alcoholic_Beverages | R | false | false | 1,250 | r | ||
#### 5.1.Surpervised_Methyl_Plot.R
COAD.methy.set
COAD.methy.blue <- COAD.methy.set[ , COAD.methy.set$dynamicColors == "blue"]
pheatmap::pheatmap(COAD.methy.blue,annotation_col = pData(COAD.methy.set)[,1:2],
main = "Methylation_Blue VS orthers_rescaled",annotation_colors = ann_colors)
| /COAD_NormalCancer_Project/1_Omic_dataset/5.1.Surpervised_Methyl_Plot.R | no_license | haojiang9999/HCA_script | R | false | false | 309 | r | #### 5.1.Surpervised_Methyl_Plot.R
COAD.methy.set
COAD.methy.blue <- COAD.methy.set[ , COAD.methy.set$dynamicColors == "blue"]
pheatmap::pheatmap(COAD.methy.blue,annotation_col = pData(COAD.methy.set)[,1:2],
main = "Methylation_Blue VS orthers_rescaled",annotation_colors = ann_colors)
|
\name{rectdistmap}
\alias{rectdistmap}
\title{
Distance Map Using Rectangular Distance Metric
}
\description{
Computes the distance map of a spatial region
based on the rectangular distance metric.
}
\usage{
rectdistmap(X, asp = 1, npasses=1, verbose=FALSE)
}
\arguments{
\item{X}{
A window (object of class ... | /man/rectdistmap.Rd | no_license | rubak/spatstat | R | false | false | 1,115 | rd | \name{rectdistmap}
\alias{rectdistmap}
\title{
Distance Map Using Rectangular Distance Metric
}
\description{
Computes the distance map of a spatial region
based on the rectangular distance metric.
}
\usage{
rectdistmap(X, asp = 1, npasses=1, verbose=FALSE)
}
\arguments{
\item{X}{
A window (object of class ... |
#' Groups
#'
#' Groups serve as the data for a few different ideas in Canvas. The first is that they can be a community in the canvas network. The second is that they can be organized by students in a course, for study or communication (but not grading). The third is that they can be organized by teachers or account ad... | /R/groups.R | no_license | icto-psy/rcanvas | R | false | false | 6,372 | r | #' Groups
#'
#' Groups serve as the data for a few different ideas in Canvas. The first is that they can be a community in the canvas network. The second is that they can be organized by students in a course, for study or communication (but not grading). The third is that they can be organized by teachers or account ad... |
# a function to load multiple files of a type from a folder into a list
import.multiple.table.files <- function(mypath, mypattern, sep, header_read, ...)
{
tmp.list.1 <- list.files(mypath, pattern = mypattern, recursive = TRUE)
tmp.list.2 <- list(length = length(tmp.list.1))
for (i in 1:length(tmp.list.1)){tmp.list.2... | /read_lists_function and head_list_function.r | no_license | RJ333/R_scripts | R | false | false | 1,530 | r | # a function to load multiple files of a type from a folder into a list
import.multiple.table.files <- function(mypath, mypattern, sep, header_read, ...)
{
tmp.list.1 <- list.files(mypath, pattern = mypattern, recursive = TRUE)
tmp.list.2 <- list(length = length(tmp.list.1))
for (i in 1:length(tmp.list.1)){tmp.list.2... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/greengrass_operations.R
\name{greengrass_stop_bulk_deployment}
\alias{greengrass_stop_bulk_deployment}
\title{Stops the execution of a bulk deployment}
\usage{
greengrass_stop_bulk_deployment(BulkDeploymentId)
}
\arguments{
\item{BulkDeployme... | /cran/paws.internet.of.things/man/greengrass_stop_bulk_deployment.Rd | permissive | johnnytommy/paws | R | false | true | 808 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/greengrass_operations.R
\name{greengrass_stop_bulk_deployment}
\alias{greengrass_stop_bulk_deployment}
\title{Stops the execution of a bulk deployment}
\usage{
greengrass_stop_bulk_deployment(BulkDeploymentId)
}
\arguments{
\item{BulkDeployme... |
context("Test cases")
#
# In the special case when the data and the initial guess are both zero, the result
# of the CCDr should be _exactly_ beta_ij = 0 and sigma_j = sqrt(n) for all i and j
#
# For details, see Section 5.2 of Aragam and Zhou (2015), in particular equations
# (33) and (34)
#
expected_rhos_value <-... | /tests/testthat/test-test_cases.R | no_license | itsrainingdata/ccdr | R | false | false | 2,220 | r | context("Test cases")
#
# In the special case when the data and the initial guess are both zero, the result
# of the CCDr should be _exactly_ beta_ij = 0 and sigma_j = sqrt(n) for all i and j
#
# For details, see Section 5.2 of Aragam and Zhou (2015), in particular equations
# (33) and (34)
#
expected_rhos_value <-... |
#' queryTable
#'
#' Function takes in a list of columns required for data output (include_cols)
#' and a list of columns required for filtering (filter_cols) and inner_joins
#' the required tables to create the requisite table with all columns included.
#' "Key" (required) tables are also included for network purpose... | /src/R/shiny/ROMOPOmics_demo/src/queryTable.R | permissive | NCBI-Codeathons/OMOPOmics | R | false | false | 1,199 | r | #' queryTable
#'
#' Function takes in a list of columns required for data output (include_cols)
#' and a list of columns required for filtering (filter_cols) and inner_joins
#' the required tables to create the requisite table with all columns included.
#' "Key" (required) tables are also included for network purpose... |
WriteOnNoteBook <- function(total.page.count)
{
count <- 0
repeat {
count <- count + 1
if(count > total.page.count){
print("Page finished")
break
}
print(paste("writing on page number",count))
}
}
WriteOnNoteBook(total.page.count = 10)
| /Pluralsight/Logic/07RepeatWithBreak.R | no_license | cyrsis/RSandBox | R | false | false | 271 | r | WriteOnNoteBook <- function(total.page.count)
{
count <- 0
repeat {
count <- count + 1
if(count > total.page.count){
print("Page finished")
break
}
print(paste("writing on page number",count))
}
}
WriteOnNoteBook(total.page.count = 10)
|
""
"Example performance estimation on the publicly available GBSG2 cancer data "
""
## Required packages
library('survival')
library('pec')
library('ggplot2')
## Load model and utility function for performance computation
source('/utils.R')
source('/HBS.R')
source('/Variable Importance and tests for HBS model.R')
... | /demo.R | permissive | alexisbellot/HBS | R | false | false | 3,326 | r | ""
"Example performance estimation on the publicly available GBSG2 cancer data "
""
## Required packages
library('survival')
library('pec')
library('ggplot2')
## Load model and utility function for performance computation
source('/utils.R')
source('/HBS.R')
source('/Variable Importance and tests for HBS model.R')
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/strava_laps.R
\name{strava_laps}
\alias{strava_laps}
\title{Get laps from Strava}
\usage{
strava_laps(data, lapType = "custom")
}
\arguments{
\item{data}{The activity id or vector of ids}
\item{lapType}{Wether to import custom laps from data... | /man/strava_laps.Rd | no_license | lynuhs/stravaR | R | false | true | 525 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/strava_laps.R
\name{strava_laps}
\alias{strava_laps}
\title{Get laps from Strava}
\usage{
strava_laps(data, lapType = "custom")
}
\arguments{
\item{data}{The activity id or vector of ids}
\item{lapType}{Wether to import custom laps from data... |
gear <- read.csv(file.choose())
ce <- read.csv(file.choose())
setwd("C:/Users/jvangeete/Google Drive/School/UCD/Thesis/datasets/Merges")
library(dplyr)
ceg <- merge(ce, gear, by = "ID")
ceg_2 <- dplyr::left_join(gear, ce, by = "ID")
write.csv(ceg_2, "ceg_2.csv")
ceg_3 <- read.csv(file.choose())
attach(ceg... | /R/thesis/bls_thesis.R | no_license | d8aninja/code | R | false | false | 457 | r | gear <- read.csv(file.choose())
ce <- read.csv(file.choose())
setwd("C:/Users/jvangeete/Google Drive/School/UCD/Thesis/datasets/Merges")
library(dplyr)
ceg <- merge(ce, gear, by = "ID")
ceg_2 <- dplyr::left_join(gear, ce, by = "ID")
write.csv(ceg_2, "ceg_2.csv")
ceg_3 <- read.csv(file.choose())
attach(ceg... |
################################################################################
############################ Denoising Autoencoder #############################
################################################################################
require("mxnet")
require("ggplot2")
require("reshape2")
# we do not need cl... | /models/04_denoising_autoencoder.R | no_license | strategist922/mxnet-examples-with-R | R | false | false | 4,698 | r | ################################################################################
############################ Denoising Autoencoder #############################
################################################################################
require("mxnet")
require("ggplot2")
require("reshape2")
# we do not need cl... |
# Fit PENCOMP -- INFLUENCE FUNCTION
library(nlme)
library(RcppArmadillo);library(Rcpp)
sourceCpp("cfunctions.cpp")
Vn = c("Time0", "MMFdos0", "age", "Sex", "ACA", "SCL70", "RNAPol", "cfcbFVC0q", "cfcbmRSS0q", "Race_1", "Race_2", "ethnic_0", "ethnic_1", "YTime")
load("tmp.RData")
### Restrict to only those taking eit... | /Causal Model v3_Model.R | no_license | yizhenxu/scleroderma-medication-effects | R | false | false | 7,225 | r | # Fit PENCOMP -- INFLUENCE FUNCTION
library(nlme)
library(RcppArmadillo);library(Rcpp)
sourceCpp("cfunctions.cpp")
Vn = c("Time0", "MMFdos0", "age", "Sex", "ACA", "SCL70", "RNAPol", "cfcbFVC0q", "cfcbmRSS0q", "Race_1", "Race_2", "ethnic_0", "ethnic_1", "YTime")
load("tmp.RData")
### Restrict to only those taking eit... |
# PROGRAMMING ASSIGNMENTS
# The zip file contains 332 comma-separated-value (CSV) files containing pollution monitoring data for fine
# matter (PM) air pollution at 332 locations in the United States. Each file contains data from a single
# monitor and the ID number for each monitor is contained in the file name. Fo... | /R_Coursera/pollutantmean.R | no_license | AlexandraMocanu/R_coursera | R | false | false | 2,181 | r | # PROGRAMMING ASSIGNMENTS
# The zip file contains 332 comma-separated-value (CSV) files containing pollution monitoring data for fine
# matter (PM) air pollution at 332 locations in the United States. Each file contains data from a single
# monitor and the ID number for each monitor is contained in the file name. Fo... |
url <- "https://comic.naver.com/genre/bestChallenge.nhn?&page="
navercomic <- NULL
i <- 0
repeat{
if (i %% 10 == 0){
cat("Now Crawling on Page Number:", i, "\n")
}else if (i == 1){
cat("Now Crawling on Page Number:", i, "\n")
}
i <- i + 1
site <- paste(url,i,sep = "")
text <- read_html(site, encodin... | /day08/navercomic.R | no_license | jaewon-jun9/R-in-multi | R | false | false | 899 | r | url <- "https://comic.naver.com/genre/bestChallenge.nhn?&page="
navercomic <- NULL
i <- 0
repeat{
if (i %% 10 == 0){
cat("Now Crawling on Page Number:", i, "\n")
}else if (i == 1){
cat("Now Crawling on Page Number:", i, "\n")
}
i <- i + 1
site <- paste(url,i,sep = "")
text <- read_html(site, encodin... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.