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 |
|---|---|---|---|---|---|---|---|---|---|
wisc_bc_df <- read.csv("C:/Users/divya/OneDrive/Documents/SEM1/ABI/Project/breastcancerwisconsindata/cancerdata.csv", stringsAsFactors = F)
str(wisc_bc_df)
head(wisc_bc_df)
table(wisc_bc_df$diagnosis)
sum(is.na(wisc_bc_df$diagnosis))
wisc_bc_df$diagnosis <- factor(wisc_bc_df$diagnosis, levels = c("B", ... | /code.R | no_license | divyanitin/BreastCancerDataAnalysis | R | false | false | 8,910 | r | wisc_bc_df <- read.csv("C:/Users/divya/OneDrive/Documents/SEM1/ABI/Project/breastcancerwisconsindata/cancerdata.csv", stringsAsFactors = F)
str(wisc_bc_df)
head(wisc_bc_df)
table(wisc_bc_df$diagnosis)
sum(is.na(wisc_bc_df$diagnosis))
wisc_bc_df$diagnosis <- factor(wisc_bc_df$diagnosis, levels = c("B", ... |
elogis <- function () {
linkfun <- function(mu) log((mu+0.5)/(1-mu+0.5))
linkinv <- function(eta) ((1+0.5)*exp(eta)-0.5)/(1+exp(eta))
mu.eta <- function(eta) (1+1)/(exp(-eta)+exp(eta)+2)
valideta <- function(eta) TRUE
link <- "empirical logit"
structure(list(linkfun=linkfun,linkinv=linkinv,mu.eta=mu.e... | /R/elogis.R | no_license | cran/RVAideMemoire | R | false | false | 378 | r | elogis <- function () {
linkfun <- function(mu) log((mu+0.5)/(1-mu+0.5))
linkinv <- function(eta) ((1+0.5)*exp(eta)-0.5)/(1+exp(eta))
mu.eta <- function(eta) (1+1)/(exp(-eta)+exp(eta)+2)
valideta <- function(eta) TRUE
link <- "empirical logit"
structure(list(linkfun=linkfun,linkinv=linkinv,mu.eta=mu.e... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/compute_functions.R
\name{httpHealthChecks.delete}
\alias{httpHealthChecks.delete}
\title{Deletes the specified HttpHealthCheck resource.}
\usage{
httpHealthChecks.delete(project, httpHealthCheck)
}
\arguments{
\item{project}{Project ID for t... | /googlecomputebeta.auto/man/httpHealthChecks.delete.Rd | permissive | GVersteeg/autoGoogleAPI | R | false | true | 1,019 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/compute_functions.R
\name{httpHealthChecks.delete}
\alias{httpHealthChecks.delete}
\title{Deletes the specified HttpHealthCheck resource.}
\usage{
httpHealthChecks.delete(project, httpHealthCheck)
}
\arguments{
\item{project}{Project ID for t... |
# D-trace
### Plotting
sparse_times <- c(0.06, 0.14, 0.96, 4.86, 140.13, 10388.93)
asymsparse_times <- c(0.06, 0.11, 1.07, 3.23, 51.24, 5451.88)
sparse_NPN_times <- c(0.07, 0.08, 0.75, 5.34, 189.67, 8182.14)
asymsparse__NPN_times <- c(0.06, 0.15, 0.91, 4.22, 29.38, 9252.86)
p_options <- c(10, 20, 50, 100, 2... | /Application/D_Trace.R | permissive | RicSalgado/DifferentialNetworks | R | false | false | 1,141 | r | # D-trace
### Plotting
sparse_times <- c(0.06, 0.14, 0.96, 4.86, 140.13, 10388.93)
asymsparse_times <- c(0.06, 0.11, 1.07, 3.23, 51.24, 5451.88)
sparse_NPN_times <- c(0.07, 0.08, 0.75, 5.34, 189.67, 8182.14)
asymsparse__NPN_times <- c(0.06, 0.15, 0.91, 4.22, 29.38, 9252.86)
p_options <- c(10, 20, 50, 100, 2... |
# XLSX download only #
install.packages("readxl")
#these libraries are necessary
library(readxl)
library(httr)
#create the URL where the dataset is stored with automatic updates every day
url <- paste("https://www.ecdc.europa.eu/sites/default/files/documents/COVID-19-geographic-disbtribution-worldwide-",format(Sys.... | /Covid19_Import_XLSX.R | no_license | AndyBuchan3/Covid19 | R | false | false | 655 | r | # XLSX download only #
install.packages("readxl")
#these libraries are necessary
library(readxl)
library(httr)
#create the URL where the dataset is stored with automatic updates every day
url <- paste("https://www.ecdc.europa.eu/sites/default/files/documents/COVID-19-geographic-disbtribution-worldwide-",format(Sys.... |
#' Construction of Independence cdf
#'
#' @inheritParams pcop
#'
#' @export
pcop.indcop <- function (copula, u = NULL) {
if (is.null(copula$distribution$cdf)) {
d <- copula$dimension
expr <- "u1"
for (i in 2:d) {
expr2 <- paste("u", i, sep = "")
expr <- paste(expr, expr2, sep = " * ")
}
... | /R/pindcop.R | no_license | AlexanderRitz/copR | R | false | false | 1,484 | r | #' Construction of Independence cdf
#'
#' @inheritParams pcop
#'
#' @export
pcop.indcop <- function (copula, u = NULL) {
if (is.null(copula$distribution$cdf)) {
d <- copula$dimension
expr <- "u1"
for (i in 2:d) {
expr2 <- paste("u", i, sep = "")
expr <- paste(expr, expr2, sep = " * ")
}
... |
library("pcalg")
library("bnlearn")
size_nodes <- c(25, 50, 75, 100)
size_neighbors <- c(2, 8)
size_samples <- c(10, 50, 100, 500)
replicates <- 40
wd <- getwd()
dir.create(path = paste0(wd, "/data"), showWarnings = FALSE)
# Perform simulations
for (r in seq_len(replicates)) {
for (p in size_nodes) {
for (n in si... | /data_sim.R | permissive | EduardoGarrido90/bopc | R | false | false | 720 | r | library("pcalg")
library("bnlearn")
size_nodes <- c(25, 50, 75, 100)
size_neighbors <- c(2, 8)
size_samples <- c(10, 50, 100, 500)
replicates <- 40
wd <- getwd()
dir.create(path = paste0(wd, "/data"), showWarnings = FALSE)
# Perform simulations
for (r in seq_len(replicates)) {
for (p in size_nodes) {
for (n in si... |
features <- read.table("/Users/tiagoassano/Documents/UCI HAR Dataset/features.txt")
labels <- read.table("/Users/tiagoassano/Documents/UCI HAR Dataset/activity_labels.txt")
header <- (features[,2])
header_clean_1 <- gsub("-", "", header)
data_1 <- read.table("/Users/tiagoassano/Documents/UCI HAR Dataset/test/X_test.txt... | /run_analysis.R | no_license | Tassano/cleaning_getting_data_course_project | R | false | false | 1,947 | r | features <- read.table("/Users/tiagoassano/Documents/UCI HAR Dataset/features.txt")
labels <- read.table("/Users/tiagoassano/Documents/UCI HAR Dataset/activity_labels.txt")
header <- (features[,2])
header_clean_1 <- gsub("-", "", header)
data_1 <- read.table("/Users/tiagoassano/Documents/UCI HAR Dataset/test/X_test.txt... |
#' Create an ExposureModel object, describing an epidemic intensity process
#'
#' @param X an $(n*T)$ by $p$ design matrix, where $n$ is the number
#' of locations, $T$ is the number of time points, and $p$ is the number
#' of exposure process parameters. Each column corresponds to a parameter,
#' while each block of $... | /R/exposureModel.R | no_license | pbrugugnoli/ABSEIR | R | false | false | 2,986 | r | #' Create an ExposureModel object, describing an epidemic intensity process
#'
#' @param X an $(n*T)$ by $p$ design matrix, where $n$ is the number
#' of locations, $T$ is the number of time points, and $p$ is the number
#' of exposure process parameters. Each column corresponds to a parameter,
#' while each block of $... |
################################################################################
################################################################################
### Home Ranges
################################################################################
#########################################################... | /home range bootstrapping.r | no_license | zybiesinger/grouper_telemetry | R | false | false | 2,494 | r | ################################################################################
################################################################################
### Home Ranges
################################################################################
#########################################################... |
rm(list = ls())
setwd("~/git_repos/tcell_cross_reactivity_covid")
require(tidyverse); require(data.table); require(ggplot2); require(seqinr); require("ape")
meta <- fread("data/parsed_host_metadata_FB_LvD.csv")
tree <- read.tree("data/cov_n2531_ml_tree_delta_rerooted.tree")
meta_filt <- meta %>%
filter(Access... | /utils/subset_metadata.R | permissive | cednotsed/tcell_cross_reactivity_covid | R | false | false | 549 | r | rm(list = ls())
setwd("~/git_repos/tcell_cross_reactivity_covid")
require(tidyverse); require(data.table); require(ggplot2); require(seqinr); require("ape")
meta <- fread("data/parsed_host_metadata_FB_LvD.csv")
tree <- read.tree("data/cov_n2531_ml_tree_delta_rerooted.tree")
meta_filt <- meta %>%
filter(Access... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/calibration.r
\name{bbqCalib}
\alias{bbqCalib}
\title{Calibrate probabilities based on bayesian binning quantile}
\usage{
bbqCalib(trnY, trnScores, tstScores, option = 1)
}
\arguments{
\item{trnScores}{vector/matrix of scores in training set}... | /man/bbqCalib.Rd | no_license | kenneth-lee-ch/calibtools | R | false | true | 622 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/calibration.r
\name{bbqCalib}
\alias{bbqCalib}
\title{Calibrate probabilities based on bayesian binning quantile}
\usage{
bbqCalib(trnY, trnScores, tstScores, option = 1)
}
\arguments{
\item{trnScores}{vector/matrix of scores in training set}... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/get_var.R
\name{get_var}
\alias{get_var}
\title{get variable from a GLM simulation}
\usage{
get_var(
file = "output.nc",
var_name,
reference = "bottom",
z_out = NULL,
t_out = NULL,
...
)
}
\arguments{
\item{file}{a string with the... | /man/get_var.Rd | no_license | rexdeng/glmtools | R | false | true | 1,605 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/get_var.R
\name{get_var}
\alias{get_var}
\title{get variable from a GLM simulation}
\usage{
get_var(
file = "output.nc",
var_name,
reference = "bottom",
z_out = NULL,
t_out = NULL,
...
)
}
\arguments{
\item{file}{a string with the... |
###########################
## Compute discrepancy
###########################
dissvar <- function(diss, weights=NULL, squared=FALSE) {
if (squared) {
diss <- diss^2
}
if (is.null(weights)) {
if (inherits(diss, "dist")) {
return(sum(diss)/(attr(diss, "Size")^2))
} else if (is.matrix(diss)) {
return(sum(... | /R/dissvar.R | no_license | cran/TraMineR | R | false | false | 877 | r | ###########################
## Compute discrepancy
###########################
dissvar <- function(diss, weights=NULL, squared=FALSE) {
if (squared) {
diss <- diss^2
}
if (is.null(weights)) {
if (inherits(diss, "dist")) {
return(sum(diss)/(attr(diss, "Size")^2))
} else if (is.matrix(diss)) {
return(sum(... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/add_pvalue.R
\name{add_pvalue}
\alias{add_pvalue}
\title{Add p-values to a ggplot}
\usage{
add_pvalue(
data,
label = NULL,
xmin = "group1",
xmax = "group2",
x = NULL,
y.position = "y.position",
label.size = 3.2,
colour = NULL,... | /man/add_pvalue.Rd | no_license | guo-cheng/ggprism | R | false | true | 12,717 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/add_pvalue.R
\name{add_pvalue}
\alias{add_pvalue}
\title{Add p-values to a ggplot}
\usage{
add_pvalue(
data,
label = NULL,
xmin = "group1",
xmax = "group2",
x = NULL,
y.position = "y.position",
label.size = 3.2,
colour = NULL,... |
# #### Usage ####
#
# a = makeCacheMatrix(matrix(rnorm(9), 3))
#
# i1 = cacheSolve(a) # create and cache inverse
# i2 = cacheSolve(a) # reuse cached inverse
#
##
# CacheMatrix: list containing matrix and it's cached inverse.
#
makeCacheMatrix <- function(x = matrix())
{
m = x # matrix
inv = NUL... | /cachematrix.R | no_license | akela1101e/ProgrammingAssignment2 | R | false | false | 771 | r | # #### Usage ####
#
# a = makeCacheMatrix(matrix(rnorm(9), 3))
#
# i1 = cacheSolve(a) # create and cache inverse
# i2 = cacheSolve(a) # reuse cached inverse
#
##
# CacheMatrix: list containing matrix and it's cached inverse.
#
makeCacheMatrix <- function(x = matrix())
{
m = x # matrix
inv = NUL... |
sp.ids <- list(
Vespula_pensylvanica = list(
Genus="Vespula",
Subgenus = "",
Species ="pensylvanica",
Subspecies="",
Sex="f",
Author = "Saussure",
Determiner="L.Ponisio",
temp.id= c(700, 732, 875, 855, 886, 979, 982, 1604, 1590, 1605,
1611, 1882, 2062, 2063, 2038, 208... | /data/speciesIDs/IDs/Wasps/Vespids.R | no_license | lponisio/Yosemite | R | false | false | 1,380 | r | sp.ids <- list(
Vespula_pensylvanica = list(
Genus="Vespula",
Subgenus = "",
Species ="pensylvanica",
Subspecies="",
Sex="f",
Author = "Saussure",
Determiner="L.Ponisio",
temp.id= c(700, 732, 875, 855, 886, 979, 982, 1604, 1590, 1605,
1611, 1882, 2062, 2063, 2038, 208... |
library(IRTmixed)
allfiles = NULL
for (obs in c(5000)) {
for (rep in 1:100) {
# save all flexmirt syntax to the Script folder
makeFlexmirtJobFile(flexmirt_Rscript_path = "~/IRTmixed_sim/Flexmirt_files/Script/",
n_obs = obs,
n_reps = rep)
# the flexmirt synta... | /drafts/flexmirt_batch.R | no_license | JihongZ/IRTmixed | R | false | false | 1,156 | r | library(IRTmixed)
allfiles = NULL
for (obs in c(5000)) {
for (rep in 1:100) {
# save all flexmirt syntax to the Script folder
makeFlexmirtJobFile(flexmirt_Rscript_path = "~/IRTmixed_sim/Flexmirt_files/Script/",
n_obs = obs,
n_reps = rep)
# the flexmirt synta... |
library(magrittr)
library(tidyverse)
library(plm)
library(stargazer)
library(scales)
library(grid)
library(gtable)
library(haven)
library(foreign)
library(lmtest)
library(broom)
library(lubridate)
library(RColorBrewer)
# post-election survey datasets
post_2004 <- "https://github.com/bjjohnson998/vid_conf/raw/master/da... | /scripts/data_transformations.R | no_license | bjjohnson998/vid_conf | R | false | false | 20,877 | r | library(magrittr)
library(tidyverse)
library(plm)
library(stargazer)
library(scales)
library(grid)
library(gtable)
library(haven)
library(foreign)
library(lmtest)
library(broom)
library(lubridate)
library(RColorBrewer)
# post-election survey datasets
post_2004 <- "https://github.com/bjjohnson998/vid_conf/raw/master/da... |
/cachematrix.R | no_license | dpuentegarcia/ProgrammingAssignment2 | R | false | false | 1,297 | r | ||
#library("changepoint")
NCR <- read.table("../data/stats/all_NCR.tsv",
header=T,stringsAsFactors=F)
ncr = NCR[,2]
names(ncr) = NCR[,1]
nsite <- read.table("data/mm10_bin5kb_with_CH_nsite.tsv",header=T,
stringsAsFactors=F)
colnames(nsite) = gsub("nsite_","",colnames(nsite))
mCH ... | /mCH_domain_calling/call_changepoint.R | permissive | yupenghe/encode_dna_dynamics | R | false | false | 3,411 | r | #library("changepoint")
NCR <- read.table("../data/stats/all_NCR.tsv",
header=T,stringsAsFactors=F)
ncr = NCR[,2]
names(ncr) = NCR[,1]
nsite <- read.table("data/mm10_bin5kb_with_CH_nsite.tsv",header=T,
stringsAsFactors=F)
colnames(nsite) = gsub("nsite_","",colnames(nsite))
mCH ... |
#' Dates for Apple Events
#'
#' A data set containing the dates of Apple media events
#' since 2005.
#'
#' @format A tibble with 47 rows and 3 variables:
#' \describe{
#' \item{event}{Description of event}
#' \item{event_date}{First date of event}
#' \item{end_event_date}{Last date of event}
#' ...
#' }
#' @sou... | /R/data.R | permissive | wizardshowing/farr | R | false | false | 5,753 | r | #' Dates for Apple Events
#'
#' A data set containing the dates of Apple media events
#' since 2005.
#'
#' @format A tibble with 47 rows and 3 variables:
#' \describe{
#' \item{event}{Description of event}
#' \item{event_date}{First date of event}
#' \item{end_event_date}{Last date of event}
#' ...
#' }
#' @sou... |
#' Add low-level theming customizations
#'
#' Compared to higher-level theme customization available in [bs_theme()], these functions
#' are a more direct interface to Bootstrap Sass, and therefore, do nothing to
#' ensure theme customizations are portable between major Bootstrap versions.
#'
#' @inheritParams bs_theme... | /R/bs-theme-layers.R | permissive | rmasiniexpert/bootstraplib | R | false | false | 4,699 | r | #' Add low-level theming customizations
#'
#' Compared to higher-level theme customization available in [bs_theme()], these functions
#' are a more direct interface to Bootstrap Sass, and therefore, do nothing to
#' ensure theme customizations are portable between major Bootstrap versions.
#'
#' @inheritParams bs_theme... |
% Generated by roxygen2 (4.0.0): do not edit by hand
\name{scale_time}
\alias{scale_time}
\title{Create a date/time scale.}
\usage{
scale_time(name, utc = FALSE, clamp = FALSE, nice = NULL, domain = NULL,
range = NULL, reverse = FALSE, round = FALSE)
}
\arguments{
\item{clamp}{If true, values that exceed the data dom... | /man/scale_time.Rd | no_license | renkun-ken/ggvis | R | false | false | 2,205 | rd | % Generated by roxygen2 (4.0.0): do not edit by hand
\name{scale_time}
\alias{scale_time}
\title{Create a date/time scale.}
\usage{
scale_time(name, utc = FALSE, clamp = FALSE, nice = NULL, domain = NULL,
range = NULL, reverse = FALSE, round = FALSE)
}
\arguments{
\item{clamp}{If true, values that exceed the data dom... |
##########################
# backward stepwise selection
##########################
### in the regusbsets function we must set the method parameter to "backward"
fit <- regsubsets(burglPerPop~., crim2, nvmax = 16, method="backward")
summ <- summary(fit)
summ
### get the adjusted R squared
summ$adjr2
which.max... | /R/datamining/applied_ml/mla_code/lect006-stepwise-backward.R | no_license | Amithmg6/FinestStatsModel | R | false | false | 389 | r |
##########################
# backward stepwise selection
##########################
### in the regusbsets function we must set the method parameter to "backward"
fit <- regsubsets(burglPerPop~., crim2, nvmax = 16, method="backward")
summ <- summary(fit)
summ
### get the adjusted R squared
summ$adjr2
which.max... |
#Mean Value Function
GO_BM_FT_MVF <- function(aMLE,bMLE,data){
tmp <- aMLE*(1-exp(-bMLE*data))
return(tmp)
}
GO_BM_FT_FailureIntensity <- function(aMLE,bMLE,data){
return(aMLE*bMLE*exp(-bMLE*data)
}
#log-likelihood function--Failure times
GO_BM_FT_LLF <- function(aMLE,bMLE,data){
lnl <- -aMLE*(1-exp(-bMLE*t... | /GO_metrics.R | no_license | willfoleyiv/SRT | R | false | false | 978 | r | #Mean Value Function
GO_BM_FT_MVF <- function(aMLE,bMLE,data){
tmp <- aMLE*(1-exp(-bMLE*data))
return(tmp)
}
GO_BM_FT_FailureIntensity <- function(aMLE,bMLE,data){
return(aMLE*bMLE*exp(-bMLE*data)
}
#log-likelihood function--Failure times
GO_BM_FT_LLF <- function(aMLE,bMLE,data){
lnl <- -aMLE*(1-exp(-bMLE*t... |
testlist <- list(id = NULL, id = NULL, booklet_id = c(8168473L, 2127314835L, 171177770L, -1942759639L, -1815221204L, 601253144L, -804651186L, 2094281728L, 860713787L, -971707632L, -1475044502L, 870040598L, -1182814578L, -1415711445L, 1901326755L, -1882837573L, 1340545259L, 1156041943L, 823641812L, -1106011624L, -10... | /dexterMST/inst/testfiles/is_person_booklet_sorted/AFL_is_person_booklet_sorted/is_person_booklet_sorted_valgrind_files/1615938311-test.R | no_license | akhikolla/updatedatatype-list1 | R | false | false | 826 | r | testlist <- list(id = NULL, id = NULL, booklet_id = c(8168473L, 2127314835L, 171177770L, -1942759639L, -1815221204L, 601253144L, -804651186L, 2094281728L, 860713787L, -971707632L, -1475044502L, 870040598L, -1182814578L, -1415711445L, 1901326755L, -1882837573L, 1340545259L, 1156041943L, 823641812L, -1106011624L, -10... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/appmesh_operations.R
\name{appmesh_describe_virtual_router}
\alias{appmesh_describe_virtual_router}
\title{Describes an existing virtual router}
\usage{
appmesh_describe_virtual_router(meshName, meshOwner, virtualRouterName)
}
\arguments{
\it... | /cran/paws.networking/man/appmesh_describe_virtual_router.Rd | permissive | TWarczak/paws | R | false | true | 1,742 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/appmesh_operations.R
\name{appmesh_describe_virtual_router}
\alias{appmesh_describe_virtual_router}
\title{Describes an existing virtual router}
\usage{
appmesh_describe_virtual_router(meshName, meshOwner, virtualRouterName)
}
\arguments{
\it... |
library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/ReliefF/lung_other.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="mse",alpha=0.6,family="gaussian",standardize=TRUE)
sink('./lung_other_065.txt',append=TR... | /Model/EN/ReliefF/lung_other/lung_other_065.R | no_license | esbgkannan/QSMART | R | false | false | 353 | r | library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/ReliefF/lung_other.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="mse",alpha=0.6,family="gaussian",standardize=TRUE)
sink('./lung_other_065.txt',append=TR... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/checkVarsStop.R
\name{checkVarsStop}
\alias{checkVarsStop}
\title{Compare vectors and report discrepancies}
\usage{
checkVarsStop(have, need)
}
\arguments{
\item{have}{vector of elements. Call the function passing ls() here.}
\item{n... | /man/checkVarsStop.Rd | permissive | tkonopka/Rpipelines | R | false | false | 611 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/checkVarsStop.R
\name{checkVarsStop}
\alias{checkVarsStop}
\title{Compare vectors and report discrepancies}
\usage{
checkVarsStop(have, need)
}
\arguments{
\item{have}{vector of elements. Call the function passing ls() here.}
\item{n... |
# Data Frames versus Tibbles!
## First lets look at strings as factors versus strings as strings
### Make a data frame (not a tibble, do not suppress the default behavior) named "test1" where the first column is the names of three of your friends and the second column is their ages
### Make a tibble named "test2" wh... | /class_code/The_Lack_of_Trouble_with_Tibbles.R | no_license | cowenannika/BSDS100 | R | false | false | 4,422 | r | # Data Frames versus Tibbles!
## First lets look at strings as factors versus strings as strings
### Make a data frame (not a tibble, do not suppress the default behavior) named "test1" where the first column is the names of three of your friends and the second column is their ages
### Make a tibble named "test2" wh... |
<!-- saved from url=(0070)http://dasan.sejong.ac.kr/~dhkim/main/software/software_emd/examples.R -->
<html><head><meta http-equiv="Content-Type" content="text/html; charset=windows-1251"><style id="clearly_highlighting_css" type="text/css">/* selection */ html.clearly_highlighting_enabled ::-moz-selection { background... | /EMD examples.R | no_license | wouldyougo/Explore_R | R | false | false | 31,639 | r |
<!-- saved from url=(0070)http://dasan.sejong.ac.kr/~dhkim/main/software/software_emd/examples.R -->
<html><head><meta http-equiv="Content-Type" content="text/html; charset=windows-1251"><style id="clearly_highlighting_css" type="text/css">/* selection */ html.clearly_highlighting_enabled ::-moz-selection { background... |
context("async_map")
test_that("async_map", {
list <- structure(as.list(1:10), names = letters[1:10])
fun <- async(function(x) {
force(x)
delay(1/100)$then(function(value) x * 2)
})
result <- await(async_map(list, fun))
expect_identical(result, as.list(unlist(list) * 2))
})
test_that("async_map w... | /tests/testthat/test-amap.R | permissive | strategist922/async-2 | R | false | false | 932 | r |
context("async_map")
test_that("async_map", {
list <- structure(as.list(1:10), names = letters[1:10])
fun <- async(function(x) {
force(x)
delay(1/100)$then(function(value) x * 2)
})
result <- await(async_map(list, fun))
expect_identical(result, as.list(unlist(list) * 2))
})
test_that("async_map w... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/optimization.R
\name{gradient_step}
\alias{gradient_step}
\title{Gradient Step}
\usage{
gradient_step(gradf, t, x)
}
\arguments{
\item{gradf}{handle to function that returns gradient of objective function}
\item{t}{step-size}
\item{x}{curre... | /sgxuST758/man/gradient_step.Rd | no_license | stevengxu/ST758-Computing-In-Statistical-Research | R | false | true | 375 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/optimization.R
\name{gradient_step}
\alias{gradient_step}
\title{Gradient Step}
\usage{
gradient_step(gradf, t, x)
}
\arguments{
\item{gradf}{handle to function that returns gradient of objective function}
\item{t}{step-size}
\item{x}{curre... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/parsnip-adam.R
\name{Auto_adam_predict_impl}
\alias{Auto_adam_predict_impl}
\title{Bridge prediction function for AUTO ADAM models}
\usage{
Auto_adam_predict_impl(object, new_data, ...)
}
\arguments{
\item{object}{An object of class \code{mod... | /man/Auto_adam_predict_impl.Rd | permissive | silverf62/modeltime | R | false | true | 533 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/parsnip-adam.R
\name{Auto_adam_predict_impl}
\alias{Auto_adam_predict_impl}
\title{Bridge prediction function for AUTO ADAM models}
\usage{
Auto_adam_predict_impl(object, new_data, ...)
}
\arguments{
\item{object}{An object of class \code{mod... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cloudbuild_functions.R
\name{operations.cancel}
\alias{operations.cancel}
\title{Starts asynchronous cancellation on a long-running operation. The servermakes a best effort to cancel the operation, but success is notguaranteed. If the serve... | /man/operations.cancel.Rd | no_license | FvD/googleContainerBuilderR | R | false | true | 1,563 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cloudbuild_functions.R
\name{operations.cancel}
\alias{operations.cancel}
\title{Starts asynchronous cancellation on a long-running operation. The servermakes a best effort to cancel the operation, but success is notguaranteed. If the serve... |
#################
# rpart to separate binary happy or not happy
#################
source('~/GitHub/World_Values_Survey/WVS_lib.R')
require(caret)
require(rpart)
require(rattle)
require(rpart.plot)
##############
# enable parallel processing
##############
require(doSNOW)
cl <- registerDoSNOW(makeCluster(4, type = "S... | /binary_FinvsSin.R | no_license | sonicrick/World_Values_Survey | R | false | false | 3,307 | r | #################
# rpart to separate binary happy or not happy
#################
source('~/GitHub/World_Values_Survey/WVS_lib.R')
require(caret)
require(rpart)
require(rattle)
require(rpart.plot)
##############
# enable parallel processing
##############
require(doSNOW)
cl <- registerDoSNOW(makeCluster(4, type = "S... |
#Get the current working directory
getwd()
#Set the working directory
setwd("C:/Users/Dilshani/Documents/DA/CW/Supplement files")
A <- read.table("A.data", sep =",", na ="?", stringsAsFactors = FALSE, header = FALSE)
B <- read.table("B.data", sep =",", na ="?", stringsAsFactors = FALSE, header = FALSE)
C <- read.... | /Q1.R | no_license | dilshanikarunaratne/Heart-disease-status-using-R | R | false | false | 11,077 | r | #Get the current working directory
getwd()
#Set the working directory
setwd("C:/Users/Dilshani/Documents/DA/CW/Supplement files")
A <- read.table("A.data", sep =",", na ="?", stringsAsFactors = FALSE, header = FALSE)
B <- read.table("B.data", sep =",", na ="?", stringsAsFactors = FALSE, header = FALSE)
C <- read.... |
getwd()
setwd("/Users/AntonioSosa/Downloads/ecob2000_lecture1/Econometrics Project")
library(foreign)
x<-read.csv("/Users/AntonioSosa/Downloads/hmda_2017_ny_all-records_labels.csv")
dat2 <- x[-c(1,4,5,7,9,11,13,16,18,21:23,26,28,30,32:40,42:50,52,54,57,59:64,66,68:71,78)]
SubsetData1 <- subset(dat2, select = agenc... | /Econ Project.R | no_license | asosa1590/HDMA | R | false | false | 11,987 | r | getwd()
setwd("/Users/AntonioSosa/Downloads/ecob2000_lecture1/Econometrics Project")
library(foreign)
x<-read.csv("/Users/AntonioSosa/Downloads/hmda_2017_ny_all-records_labels.csv")
dat2 <- x[-c(1,4,5,7,9,11,13,16,18,21:23,26,28,30,32:40,42:50,52,54,57,59:64,66,68:71,78)]
SubsetData1 <- subset(dat2, select = agenc... |
install.packages('rvest')
install.packages('KoNLP')
install.packages('stringi')
install.packages('dplyr')
install.packages('reshape2')
install.packages('ggplot2')
install.packages('wordcloud')
library(rvest)
library(KoNLP)
#Error: package ??rJava?? could not be loaded
#Try re-installing Java and make sure R and Java ... | /Martian.R | no_license | starsieun/Language_Processing_with_Martian | R | false | false | 6,361 | r |
install.packages('rvest')
install.packages('KoNLP')
install.packages('stringi')
install.packages('dplyr')
install.packages('reshape2')
install.packages('ggplot2')
install.packages('wordcloud')
library(rvest)
library(KoNLP)
#Error: package ??rJava?? could not be loaded
#Try re-installing Java and make sure R and Java ... |
library(lattice)
library("vioplot")
setwd("C:/devstore/data_mining/homework3/")
klient1 = read.csv("klient1.txt", col.names = as.matrix("hours"))
klient3 = read.csv("klient3.txt", col.names = as.matrix("hours"))
plot(density(klient1$hours, kernel = "gaussian", bw=25))
lines(density(klient3$hours, kernel = "gaussian... | /homework3/HW3_B66081.R | no_license | valuko/data_mining_2017 | R | false | false | 4,784 | r |
library(lattice)
library("vioplot")
setwd("C:/devstore/data_mining/homework3/")
klient1 = read.csv("klient1.txt", col.names = as.matrix("hours"))
klient3 = read.csv("klient3.txt", col.names = as.matrix("hours"))
plot(density(klient1$hours, kernel = "gaussian", bw=25))
lines(density(klient3$hours, kernel = "gaussian... |
#Variables expected:
#dat
#iv
#maybe write a function that plots the psychometric functions for a dataset / experiment /criterion,
plotIndividDataAndCurves <- function(dat,iv,factors,psychometricCurves=NULL,
worstCasePsychometricRegion=NULL,threshes=NULL ) {
#factors must be a n... | /analyze/plotIndividDataWithPsychometricCurves.R | permissive | alexholcombe/spatiotopic-motion | R | false | false | 3,435 | r | #Variables expected:
#dat
#iv
#maybe write a function that plots the psychometric functions for a dataset / experiment /criterion,
plotIndividDataAndCurves <- function(dat,iv,factors,psychometricCurves=NULL,
worstCasePsychometricRegion=NULL,threshes=NULL ) {
#factors must be a n... |
get.returns.table <- function(investment, avg.return, sell.year, pretty.print=FALSE) {
value <- function(period) {
current.value = investment * ((1 + (avg.return - annual.expense))) ^ period
if (pretty.print) {
current.value = format(current.value, nsmall=2,
decimal.mark=".... | /server.R | no_license | strawberrysocialist/data_project | R | false | false | 6,281 | r | get.returns.table <- function(investment, avg.return, sell.year, pretty.print=FALSE) {
value <- function(period) {
current.value = investment * ((1 + (avg.return - annual.expense))) ^ period
if (pretty.print) {
current.value = format(current.value, nsmall=2,
decimal.mark=".... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/AllGenerics.R, R/plotDEGPCA-methods.R
\docType{methods}
\name{plotDEGPCA}
\alias{plotDEGPCA}
\alias{plotDEGPCA,DESeqResults,SummarizedExperiment-method}
\alias{plotDEGPCA,DESeqResults,bcbioRNASeq-method}
\alias{plotDEGPCA,DESeqResults,DESeqDa... | /man/plotDEGPCA.Rd | permissive | enginbozaba/bcbioRNASeq | R | false | true | 4,077 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/AllGenerics.R, R/plotDEGPCA-methods.R
\docType{methods}
\name{plotDEGPCA}
\alias{plotDEGPCA}
\alias{plotDEGPCA,DESeqResults,SummarizedExperiment-method}
\alias{plotDEGPCA,DESeqResults,bcbioRNASeq-method}
\alias{plotDEGPCA,DESeqResults,DESeqDa... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/var_res.R
\name{varyres}
\alias{varyres}
\title{A variable-resolution heat map generator}
\usage{
varyres(dataset, fun = mean, cutoff, max = 6)
}
\arguments{
\item{dataset}{data frame with spatial data: x-coordinates (x), y coordinates (y), a... | /man/varyres.Rd | no_license | cwickham/varyres | R | false | true | 960 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/var_res.R
\name{varyres}
\alias{varyres}
\title{A variable-resolution heat map generator}
\usage{
varyres(dataset, fun = mean, cutoff, max = 6)
}
\arguments{
\item{dataset}{data frame with spatial data: x-coordinates (x), y coordinates (y), a... |
#
# 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(shiny)
library(tidyverse)
library(ggmap)
library(maptools)
library(MAP)
library(magrittr)
library(forcats)... | /Vision_Zero_App.R | no_license | hagk17/MA615-MappingHW | R | false | false | 3,512 | 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(shiny)
library(tidyverse)
library(ggmap)
library(maptools)
library(MAP)
library(magrittr)
library(forcats)... |
# Exercise 1: calling built-in functions
# Create a variable `my_name` that contains your name
my_name <- "Christoph Knappik"
print(my_name)
# Create a variable `name_length` that holds how many letters (including spaces)
# are in your name (use the `nchar()` function)
name_length <- nchar(my_name)
# Print the num... | /chapter-06-exercises/exercise-1/exercise.R | permissive | cjknappik/book-exercises | R | false | false | 1,655 | r | # Exercise 1: calling built-in functions
# Create a variable `my_name` that contains your name
my_name <- "Christoph Knappik"
print(my_name)
# Create a variable `name_length` that holds how many letters (including spaces)
# are in your name (use the `nchar()` function)
name_length <- nchar(my_name)
# Print the num... |
library(rbace)
# get_papers
#
# Params:
#
# * query: search query
# * params: parameters for the search in JSON format
# * from: publication date lower bound in the form YYYY-MM-DD
# * to: publication date upper bound in the form YYYY-MM-DD
# * article_types: in the form of an array of identifiers of article ... | /server/preprocessing/other-scripts/base.R | permissive | patrickdsouza07/Headstart | R | false | false | 7,476 | r | library(rbace)
# get_papers
#
# Params:
#
# * query: search query
# * params: parameters for the search in JSON format
# * from: publication date lower bound in the form YYYY-MM-DD
# * to: publication date upper bound in the form YYYY-MM-DD
# * article_types: in the form of an array of identifiers of article ... |
library(miceadds)
### Name: index.dataframe
### Title: R Utilities: Include an Index to a Data Frame
### Aliases: index.dataframe
### Keywords: R utilities
### ** Examples
dfr <- matrix( 2*1:12-3, 4,3 )
colnames(dfr) <- paste0("X",1:ncol(dfr))
index.dataframe( dfr)
## index X1 X2 X3
## 1 1 -1 7 15
... | /data/genthat_extracted_code/miceadds/examples/index.dataframe.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 654 | r | library(miceadds)
### Name: index.dataframe
### Title: R Utilities: Include an Index to a Data Frame
### Aliases: index.dataframe
### Keywords: R utilities
### ** Examples
dfr <- matrix( 2*1:12-3, 4,3 )
colnames(dfr) <- paste0("X",1:ncol(dfr))
index.dataframe( dfr)
## index X1 X2 X3
## 1 1 -1 7 15
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fftrees_threshold_numeric_grid.R
\name{fftrees_threshold_numeric_grid}
\alias{fftrees_threshold_numeric_grid}
\title{Perform a grid search over thresholds and return accuracy statistics for a given numeric cue}
\usage{
fftrees_threshold_numer... | /man/fftrees_threshold_numeric_grid.Rd | no_license | ndphillips/FFTrees | R | false | true | 2,322 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fftrees_threshold_numeric_grid.R
\name{fftrees_threshold_numeric_grid}
\alias{fftrees_threshold_numeric_grid}
\title{Perform a grid search over thresholds and return accuracy statistics for a given numeric cue}
\usage{
fftrees_threshold_numer... |
# Load Library
library(tidyverse)
library(dplyr)
library(cellranger)
# Set Directory
setwd("../2019 Ewha Data Analysis Contest/data")
# Load Data
# 1) 발화기기
## 경로 지정 및 데이터 목록
dir <- ("C:\\Users\\Chanmi Yoo\\Desktop\\ESAA\\2019 Ewha Data Analysis Contest\\data\\fire machine")
file_list <- list.files(dir... | /2019 Ewha Bigdata Contest/merge.R | no_license | wldusdhso/ESAA | R | false | false | 4,943 | r | # Load Library
library(tidyverse)
library(dplyr)
library(cellranger)
# Set Directory
setwd("../2019 Ewha Data Analysis Contest/data")
# Load Data
# 1) 발화기기
## 경로 지정 및 데이터 목록
dir <- ("C:\\Users\\Chanmi Yoo\\Desktop\\ESAA\\2019 Ewha Data Analysis Contest\\data\\fire machine")
file_list <- list.files(dir... |
library("ggplot2")
library("ggthemes")
library("scales")
library("dplyr")
library("mice")
library("randomForest")
train <- read.csv("../input/train.csv", stringsAsFactors = F)
test <- read.csv("../input/test.csv", stringsAsFactors = F)
full <- bind_rows(train, test)
str(full)
full$Title <- gsub("(.*, )|(\\..*)", "", fu... | /src/r/kernels/orbanjan-exploring-survival-on-the-titanic-new/script/exploring-survival-on-the-titanic-new.R | no_license | PRL-PRG/trustworthy-titanic | R | false | false | 4,898 | r | library("ggplot2")
library("ggthemes")
library("scales")
library("dplyr")
library("mice")
library("randomForest")
train <- read.csv("../input/train.csv", stringsAsFactors = F)
test <- read.csv("../input/test.csv", stringsAsFactors = F)
full <- bind_rows(train, test)
str(full)
full$Title <- gsub("(.*, )|(\\..*)", "", fu... |
plot1 <- function() {
# Unzip Zip File
file <-unzip("exdata-data-household_power_consumption.zip")
# Read entire file into memory.
# I have 8 GB RAM and I calculated that the entire data will fit in memory
data <- read.table(file,header=T,sep=";",as.is=F,na.strings=c("",NA,"?"),stringsAsFactors=F)
# Subset pl... | /plot1.R | no_license | AustinInsights/ExData_Plotting1 | R | false | false | 691 | r | plot1 <- function() {
# Unzip Zip File
file <-unzip("exdata-data-household_power_consumption.zip")
# Read entire file into memory.
# I have 8 GB RAM and I calculated that the entire data will fit in memory
data <- read.table(file,header=T,sep=";",as.is=F,na.strings=c("",NA,"?"),stringsAsFactors=F)
# Subset pl... |
## Navigating EMBL's ArrayExpress repository
# direct interrogation of the EMBL-EBI archive, with queryAE
library(BiocInstaller)
biocLite("ArrayExpress")
library(ArrayExpress)
sets = queryAE(keywords = "glioblastoma", species = "homo+sapiens") # queryAE function
dim(sets)
# the DT package, if I say data table sets, ... | /Section-2.1, Navigating EMBL's ArrayExpress repository.R | no_license | tzzhangjuan1/Edx---HarvardX-PH525.5x | R | false | false | 607 | r | ## Navigating EMBL's ArrayExpress repository
# direct interrogation of the EMBL-EBI archive, with queryAE
library(BiocInstaller)
biocLite("ArrayExpress")
library(ArrayExpress)
sets = queryAE(keywords = "glioblastoma", species = "homo+sapiens") # queryAE function
dim(sets)
# the DT package, if I say data table sets, ... |
\name{-.popgraph}
\alias{-.popgraph}
\title{Overload '-' operator for pairs of \code{popgraph} objects}
\usage{
\method{-}{popgraph}(e1, e2)
}
\arguments{
\item{e1}{A \code{popgraph} object reprenting the
offspring.}
\item{e2}{A \code{popgraph} object representing the
parent.}
}
\value{
A new \code{popgraph} o... | /man/popgraph-operator-minus.Rd | no_license | cran/popgraph | R | false | false | 866 | rd | \name{-.popgraph}
\alias{-.popgraph}
\title{Overload '-' operator for pairs of \code{popgraph} objects}
\usage{
\method{-}{popgraph}(e1, e2)
}
\arguments{
\item{e1}{A \code{popgraph} object reprenting the
offspring.}
\item{e2}{A \code{popgraph} object representing the
parent.}
}
\value{
A new \code{popgraph} o... |
#' Dataset on well being
#'
#' @description This is a data set on well being collected with ambulatory assessment. For more information see the paper by Crayen et al. (2012).
#'
#' @docType data
#'
#' @usage data(MoodRegulation)
#'
#' @format The dataset is in a long format, where every observation of one person at one... | /R/dataMoodRegulation.R | no_license | MattisvdBergh/LCT | R | false | false | 860 | r | #' Dataset on well being
#'
#' @description This is a data set on well being collected with ambulatory assessment. For more information see the paper by Crayen et al. (2012).
#'
#' @docType data
#'
#' @usage data(MoodRegulation)
#'
#' @format The dataset is in a long format, where every observation of one person at one... |
context("dictionary tidiers")
if (requireNamespace("quanteda", quietly = TRUE)) {
test_that("can tidy a quanteda dictionary", {
lst <- list(terror = c("terrorism", "terrorists", "threat"),
economy = c("jobs", "business", "grow", "work"))
d <- quanteda::dictionary(lst)
td <- tidy.dictiona... | /tests/testthat/test-dictionary-tidiers.R | permissive | andreemidio/tidytext | R | false | false | 630 | r | context("dictionary tidiers")
if (requireNamespace("quanteda", quietly = TRUE)) {
test_that("can tidy a quanteda dictionary", {
lst <- list(terror = c("terrorism", "terrorists", "threat"),
economy = c("jobs", "business", "grow", "work"))
d <- quanteda::dictionary(lst)
td <- tidy.dictiona... |
weightedEM = function(X, w=NULL, lmin=NULL, crit=1e-4,
maxiter=1000, initEst=NULL, computeloglik=F){
#
# Carries out a rowwise weighted EM algorithm to estimate
# mu and Sigma of incomplete Gaussian data.
#
# Arguments:
# X : n by d data matrix or data frame.
#... | /R/cellwiseWeights.R | no_license | cran/cellWise | R | false | false | 18,413 | r |
weightedEM = function(X, w=NULL, lmin=NULL, crit=1e-4,
maxiter=1000, initEst=NULL, computeloglik=F){
#
# Carries out a rowwise weighted EM algorithm to estimate
# mu and Sigma of incomplete Gaussian data.
#
# Arguments:
# X : n by d data matrix or data frame.
#... |
/monte_carlo/mc_linear_0.25_1cy.R | no_license | yeshancqcq/GEO420_data | R | false | false | 3,067 | r | ||
#############################
##########- 实验3 -##########
#############################
# GARCH(1, 1)的数值模拟
# 本实验的主要目标是学习GARCH(1, 1)的估计方法,以及理解GARCH模型的估计精确度
# 过程如下
# # 1. 先生成一个GARCH(1, 1)模型的参数,由参数和随机项模拟出收益率序列
# # 2. 然后估计模拟收益率序列的GARCH(1, 1)参数
# # 3. 对比估计的参数和实际的参数,分析GARCH(1, 1)模型的估计精度
library(fGarch)
setwd(... | /GARCH_1_1.R | no_license | alonegg/jupyters | R | false | false | 3,877 | r | #############################
##########- 实验3 -##########
#############################
# GARCH(1, 1)的数值模拟
# 本实验的主要目标是学习GARCH(1, 1)的估计方法,以及理解GARCH模型的估计精确度
# 过程如下
# # 1. 先生成一个GARCH(1, 1)模型的参数,由参数和随机项模拟出收益率序列
# # 2. 然后估计模拟收益率序列的GARCH(1, 1)参数
# # 3. 对比估计的参数和实际的参数,分析GARCH(1, 1)模型的估计精度
library(fGarch)
setwd(... |
context("http")
test_that("http works", {
skip_on_cran()
library("crul")
res <- HttpClient$new("https://httpbin.org/status/418")$get()
expect_message(http(res, behavior = "message"), "I'm a teapot")
expect_warning(http(res, behavior = "warning"), "I'm a teapot")
expect_error(http(res), "I'm a teapot")
... | /data/genthat_extracted_code/fauxpas/tests/test-http.R | no_license | surayaaramli/typeRrh | R | false | false | 1,461 | r | context("http")
test_that("http works", {
skip_on_cran()
library("crul")
res <- HttpClient$new("https://httpbin.org/status/418")$get()
expect_message(http(res, behavior = "message"), "I'm a teapot")
expect_warning(http(res, behavior = "warning"), "I'm a teapot")
expect_error(http(res), "I'm a teapot")
... |
#install.packages("twitteR")
#install.packages('openssl')
library(twitteR)
# Log in as 'swbrewer'
api_key <- "c2eiHpCAjrTQ0jX8AasPfzUoG"
api_secret <- "RqMjyMMTg84ktM1JLlz14TUhbPMsb49tv3l8UWxDzgovTol6BH"
access_token <- "15043068-tzRAOCaQQrgz0gfZeOFbANDGJ0dG0EknHftXKlUvA"
access_token_secret <- "y43mE6qZOd6DUa7jetlXre... | /Proj575 All.R | no_license | swbrewer/IDS575-Project | R | false | false | 18,195 | r | #install.packages("twitteR")
#install.packages('openssl')
library(twitteR)
# Log in as 'swbrewer'
api_key <- "c2eiHpCAjrTQ0jX8AasPfzUoG"
api_secret <- "RqMjyMMTg84ktM1JLlz14TUhbPMsb49tv3l8UWxDzgovTol6BH"
access_token <- "15043068-tzRAOCaQQrgz0gfZeOFbANDGJ0dG0EknHftXKlUvA"
access_token_secret <- "y43mE6qZOd6DUa7jetlXre... |
library(gpuR)
context("CPU gpuVector classes")
current_context <- set_device_context("cpu")
set.seed(123)
test_that("integer vector class present", {
has_cpu_skip()
A <- seq.int(10)
gpuA <- gpuVector(A)
expect_is(gpuA, "igpuVector")
expect_is(gpuA@address, "externalptr... | /tests/testthat/test_cpu_gpuVector_classes.R | no_license | cran/gpuR | R | false | false | 3,025 | r | library(gpuR)
context("CPU gpuVector classes")
current_context <- set_device_context("cpu")
set.seed(123)
test_that("integer vector class present", {
has_cpu_skip()
A <- seq.int(10)
gpuA <- gpuVector(A)
expect_is(gpuA, "igpuVector")
expect_is(gpuA@address, "externalptr... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/build_interface.R
\name{buildManagementTabPanels}
\alias{buildManagementTabPanels}
\title{Build tab panels}
\usage{
buildManagementTabPanels(input, output, session)
}
\arguments{
\item{input}{shiny input values list.}
\item{output}{shiny out... | /man/buildManagementTabPanels.Rd | no_license | nathanvaughan1/DST | R | false | true | 501 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/build_interface.R
\name{buildManagementTabPanels}
\alias{buildManagementTabPanels}
\title{Build tab panels}
\usage{
buildManagementTabPanels(input, output, session)
}
\arguments{
\item{input}{shiny input values list.}
\item{output}{shiny out... |
library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/Classifier/thyroid.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.55,family="gaussian",standardize=TRUE)
sink('./thyroid_063.txt',append=TRUE... | /Model/EN/Classifier/thyroid/thyroid_063.R | no_license | esbgkannan/QSMART | R | false | false | 351 | r | library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/Classifier/thyroid.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.55,family="gaussian",standardize=TRUE)
sink('./thyroid_063.txt',append=TRUE... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/MarkovTest.R
\name{MarkovTest}
\alias{MarkovTest}
\alias{optimal_weights_multiple}
\alias{optimal_weights_matrix}
\title{Log-rank based test for the validity of the Markov assumption}
\usage{
MarkovTest(
data,
id,
formula = NULL,
tran... | /man/MarkovTest.Rd | no_license | damjanm/mstate-1 | R | false | true | 5,631 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/MarkovTest.R
\name{MarkovTest}
\alias{MarkovTest}
\alias{optimal_weights_multiple}
\alias{optimal_weights_matrix}
\title{Log-rank based test for the validity of the Markov assumption}
\usage{
MarkovTest(
data,
id,
formula = NULL,
tran... |
shinyUI(pageWithSidebar(
headerPanel("Graphical Demonstration of the Pricipal of Least Mean Squared Error (MSE) Estimation"),
sidebarPanel(width=2,
sliderInput('beta',
'Guess at the slope of the Minimum Mean Square Error (MSE) regression line',
value = 1.0, min... | /ui.R | no_license | psymosek/Shiny_Application | R | false | false | 1,729 | r | shinyUI(pageWithSidebar(
headerPanel("Graphical Demonstration of the Pricipal of Least Mean Squared Error (MSE) Estimation"),
sidebarPanel(width=2,
sliderInput('beta',
'Guess at the slope of the Minimum Mean Square Error (MSE) regression line',
value = 1.0, min... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/firevat_report.R
\name{GetOptimizedSignatures}
\alias{GetOptimizedSignatures}
\title{GetOptimizedSignatures}
\usage{
GetOptimizedSignatures(data, mutations.type = "refined",
signatures = "all")
}
\arguments{
\item{data}{A list of main data ... | /man/GetOptimizedSignatures.Rd | permissive | ai-genomics/FV | R | false | true | 761 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/firevat_report.R
\name{GetOptimizedSignatures}
\alias{GetOptimizedSignatures}
\title{GetOptimizedSignatures}
\usage{
GetOptimizedSignatures(data, mutations.type = "refined",
signatures = "all")
}
\arguments{
\item{data}{A list of main data ... |
#library needed
library(tidyverse)
#load the 4 data sets and assign each to a variable name
confirmed <- read_csv("https://raw.githubusercontent.com/CSSEGISandData/COVID-19/master/csse_covid_19_data/csse_covid_19_time_series/time_series_covid19_confirmed_global.csv")
deaths<- read_csv("https://raw.githubusercontent.... | /newproject375 (2).R | no_license | aaskaryar/Data-Science-Tidey-Dataset | R | false | false | 3,158 | r | #library needed
library(tidyverse)
#load the 4 data sets and assign each to a variable name
confirmed <- read_csv("https://raw.githubusercontent.com/CSSEGISandData/COVID-19/master/csse_covid_19_data/csse_covid_19_time_series/time_series_covid19_confirmed_global.csv")
deaths<- read_csv("https://raw.githubusercontent.... |
# Name: Nikoula, Latifah & Nikos
# Date: 13 January 2015
rm(list=ls()) # clear the workspace
getwd()# make sure the data directory
# Required packages and functions
lib <- c("raster","sp","rgdal", "knitr")
sapply(lib, function(...) require(..., character.only = TRUE))
# Load functions:
source("R/rmse.R")
# load t... | /main.R | no_license | tziol001/Assignment7 | R | false | false | 2,861 | r | # Name: Nikoula, Latifah & Nikos
# Date: 13 January 2015
rm(list=ls()) # clear the workspace
getwd()# make sure the data directory
# Required packages and functions
lib <- c("raster","sp","rgdal", "knitr")
sapply(lib, function(...) require(..., character.only = TRUE))
# Load functions:
source("R/rmse.R")
# load t... |
vis.boxcoxu.old <-
function(lambda = sample( c(-1, -0.5, 0, 1/3, 1/2, 1, 2), 1)) {
if( !requireNamespace('tkrplot', quietly = TRUE) ) stop('This function depends on the tkrplot package being available')
y <- rnorm(1000, 7, 2)
if( min(y) <= 0 ) y <- y - min(y)+0.05
if (lambda==0) {
y <- exp(y)
... | /R/vis.boxcoxu.R | no_license | glsnow/TeachingDemos | R | false | false | 4,801 | r | vis.boxcoxu.old <-
function(lambda = sample( c(-1, -0.5, 0, 1/3, 1/2, 1, 2), 1)) {
if( !requireNamespace('tkrplot', quietly = TRUE) ) stop('This function depends on the tkrplot package being available')
y <- rnorm(1000, 7, 2)
if( min(y) <= 0 ) y <- y - min(y)+0.05
if (lambda==0) {
y <- exp(y)
... |
# # # DEN summary -----
# #
# den <- eliteDB.connections(pass )
# b <- den
# load("~/My Dropbox/Elite og Tal/Projekter/Magtelite-projektet 2016/Magtelite R/den.db.Rda")
# den <- den.db
# library(qlcMatrix)
# summary.den <- function(den){
# incidence <- xtabs(data = den, formula = ~ NAME + AFFILIATION, sparse ... | /R/dev.R | no_license | antongrau/soc.elite | R | false | false | 9,057 | r | # # # DEN summary -----
# #
# den <- eliteDB.connections(pass )
# b <- den
# load("~/My Dropbox/Elite og Tal/Projekter/Magtelite-projektet 2016/Magtelite R/den.db.Rda")
# den <- den.db
# library(qlcMatrix)
# summary.den <- function(den){
# incidence <- xtabs(data = den, formula = ~ NAME + AFFILIATION, sparse ... |
#' @title Builds a contrast code from character vector
#'
#' @description This function constructs a contrast code from a character
#' variable. It is useful when one needs to recode a two-category character
#' variable to a numeric one.
#'
#' @param vector A character vector.
#' @param cond_a A character string to... | /R/build_contrast.R | permissive | cedricbatailler/JSmediation | R | false | false | 1,663 | r | #' @title Builds a contrast code from character vector
#'
#' @description This function constructs a contrast code from a character
#' variable. It is useful when one needs to recode a two-category character
#' variable to a numeric one.
#'
#' @param vector A character vector.
#' @param cond_a A character string to... |
setwd('/Users/jhelvy/Documents/GitHub/logitr/vignettes/examples')
# Load logitr package
library('logitr')
# Load the reformatted 'Yogurt' data set from the mlogit package
data(yogurt)
# ============================================================================
# Estimate Homogeneous MNL models
# Run a MNL model i... | /vignettes/examples/examples.R | permissive | ahcyip/logitr | R | false | false | 4,084 | r | setwd('/Users/jhelvy/Documents/GitHub/logitr/vignettes/examples')
# Load logitr package
library('logitr')
# Load the reformatted 'Yogurt' data set from the mlogit package
data(yogurt)
# ============================================================================
# Estimate Homogeneous MNL models
# Run a MNL model i... |
# Read Data
data = read.csv("household_power_consumption.txt",sep=";",skip=66637,nrows=2880,header=F,
col.names=c("Date","Time","Global_active_power","Global_reactive_power",
"Voltage","Global_intensity","Sub_metering_1","Sub_metering_2",
"Sub_mete... | /plot3.R | no_license | rarce/ExData_Plotting1 | R | false | false | 816 | r | # Read Data
data = read.csv("household_power_consumption.txt",sep=";",skip=66637,nrows=2880,header=F,
col.names=c("Date","Time","Global_active_power","Global_reactive_power",
"Voltage","Global_intensity","Sub_metering_1","Sub_metering_2",
"Sub_mete... |
library(ellipsenm)
setwd('C:\\Users\\mari1\\Desktop\\Certhia\\Certhia\\M_certhia\\Un_Dil')
d<-as.data.frame(fread("coordinatesCerthiaOnlyUniqueDiluted.tsv"))
head(d)
d <- cbind(d$species, d$decimalLongitude, d$decimalLatitude)
colnames(d) <- c('species', 'long', 'lat')
write.csv(d,"coordinatesCerthiaOnlyUniqueDil... | /ellipsCerthia_.R | no_license | msimoes123/Certhia_Ellipses | R | false | false | 18,666 | r | library(ellipsenm)
setwd('C:\\Users\\mari1\\Desktop\\Certhia\\Certhia\\M_certhia\\Un_Dil')
d<-as.data.frame(fread("coordinatesCerthiaOnlyUniqueDiluted.tsv"))
head(d)
d <- cbind(d$species, d$decimalLongitude, d$decimalLatitude)
colnames(d) <- c('species', 'long', 'lat')
write.csv(d,"coordinatesCerthiaOnlyUniqueDil... |
\name{CTF}
\alias{CTF}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Cease-to-flow (CTF) spell statistics
}
\description{
Calculates summary statistics describing cease-to-flow spell characteristics.}
\usage{
CTF(flow.ts, threshold = 0.1)
}
%- maybe also 'usage' for other objects documented her... | /man/CTF.Rd | no_license | nickbond/hydrostats | R | false | false | 1,170 | rd | \name{CTF}
\alias{CTF}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Cease-to-flow (CTF) spell statistics
}
\description{
Calculates summary statistics describing cease-to-flow spell characteristics.}
\usage{
CTF(flow.ts, threshold = 0.1)
}
%- maybe also 'usage' for other objects documented her... |
## c:/Dropbox/PublicShinyApps/MDRI-App/ui.R
## Chandler Lutz
## Questions/comments: cl.eco@cbs.dk
## $Revisions: 1.0.0 $Date: 2016-11-10
mdri.announcement <- readRDS("MDRI_announcement.rds")
shinyUI(fluidPage(
titlePanel("The Mortgage Default Risk Index (MDRI)"),
sidebarLayout(
si... | /ui.R | no_license | ChandlerLutz/MDRI-App | R | false | false | 2,324 | r | ## c:/Dropbox/PublicShinyApps/MDRI-App/ui.R
## Chandler Lutz
## Questions/comments: cl.eco@cbs.dk
## $Revisions: 1.0.0 $Date: 2016-11-10
mdri.announcement <- readRDS("MDRI_announcement.rds")
shinyUI(fluidPage(
titlePanel("The Mortgage Default Risk Index (MDRI)"),
sidebarLayout(
si... |
df_2016 <- data.frame(stringsAsFactors=FALSE,
Date = c("28 Jun – 1 Jul 2016", "30-Jun-16", "27–30 Jun 2016",
"28–29 Jun 2016", "26–29 Jun 2016", "23–26 Jun 2016",
"23–26 Jun 2016", "23-Jun-16", "20–22 Jun 2016",
... | /raw_import.R | no_license | ekothe/auspol | R | false | false | 114,347 | r | df_2016 <- data.frame(stringsAsFactors=FALSE,
Date = c("28 Jun – 1 Jul 2016", "30-Jun-16", "27–30 Jun 2016",
"28–29 Jun 2016", "26–29 Jun 2016", "23–26 Jun 2016",
"23–26 Jun 2016", "23-Jun-16", "20–22 Jun 2016",
... |
MR <- function(y, x, check.data=TRUE, lean=FALSE, ...)
{
if (check.data) {
if (any(apply(y, 1, sum) < 1.0E-8))
stop(paste("Species data have zero abundances for the following rows:", paste(which(apply(y, 1, sum) < 1.0E-8), collapse=",")))
if (any(apply(y, 2, sum) < 1.0E-8))
stop(paste("Spe... | /R/MR.r | no_license | cran/rioja | R | false | false | 3,990 | r | MR <- function(y, x, check.data=TRUE, lean=FALSE, ...)
{
if (check.data) {
if (any(apply(y, 1, sum) < 1.0E-8))
stop(paste("Species data have zero abundances for the following rows:", paste(which(apply(y, 1, sum) < 1.0E-8), collapse=",")))
if (any(apply(y, 2, sum) < 1.0E-8))
stop(paste("Spe... |
\name{ztobins}
\alias{ztobins}
\title{
Binning of z-scores and estimation of the probabilities in each bin for the null and non-null states.
}
\description{
For each study, the function discretizes the z-scores into bins and estimates the probabilities in each bin for the null and non-null states.
}
\usage{
ztobins(zma... | /man/ztobins.Rd | no_license | talgalili/repfdr | R | false | false | 2,615 | rd | \name{ztobins}
\alias{ztobins}
\title{
Binning of z-scores and estimation of the probabilities in each bin for the null and non-null states.
}
\description{
For each study, the function discretizes the z-scores into bins and estimates the probabilities in each bin for the null and non-null states.
}
\usage{
ztobins(zma... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/download_works.R
\name{download_by_id}
\alias{download_by_id}
\title{Download gutenberg work by id and format}
\usage{
download_by_id(id, output.dir = NULL, sleep_time = 5,
file_format = "text/plain", zip = FALSE)
}
\arguments{
\item{id}{a ... | /gutenbergr/man/download_by_id.Rd | no_license | james-jenkins/authorship_attribution | R | false | true | 800 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/download_works.R
\name{download_by_id}
\alias{download_by_id}
\title{Download gutenberg work by id and format}
\usage{
download_by_id(id, output.dir = NULL, sleep_time = 5,
file_format = "text/plain", zip = FALSE)
}
\arguments{
\item{id}{a ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/jdbc.r
\docType{methods}
\name{dbConnect,DrillJDBCDriver-method}
\alias{dbConnect,DrillJDBCDriver-method}
\title{Connect to Drill JDBC with your own connection string}
\usage{
\S4method{dbConnect}{DrillJDBCDriver}(drv, url, user = "", passwor... | /man/dbConnect-DrillJDBCDriver-method.Rd | no_license | firebitsbr/sergeant-caffeinated | R | false | true | 1,025 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/jdbc.r
\docType{methods}
\name{dbConnect,DrillJDBCDriver-method}
\alias{dbConnect,DrillJDBCDriver-method}
\title{Connect to Drill JDBC with your own connection string}
\usage{
\S4method{dbConnect}{DrillJDBCDriver}(drv, url, user = "", passwor... |
library(shiny)
shinyUI(fluidPage(
titlePanel("Within Host Drug Action: DHA, piperaquine + drug C"),
# sidebarLayout(
# sidebarPanel(
fluidRow(
#sliderInput("initn", "Initial total parasites: ", min = 1000, max=10^10, value=100),
column(3,
sliderInput("initn", "Log10 of initial total par... | /DHA-PIP-C-scale/ui.R | no_license | slphyx/within-host-shiny-malaria | R | false | false | 3,458 | r | library(shiny)
shinyUI(fluidPage(
titlePanel("Within Host Drug Action: DHA, piperaquine + drug C"),
# sidebarLayout(
# sidebarPanel(
fluidRow(
#sliderInput("initn", "Initial total parasites: ", min = 1000, max=10^10, value=100),
column(3,
sliderInput("initn", "Log10 of initial total par... |
# library('rHighcharts',lib='C:/Progra~1/R/R-3.2.0/library')
shinyUI(fluidPage(
titlePanel("Monthly Review"),
fluidRow(
column(3,
selectInput("disc", "Discipline:",
list("Civil" = "Civil",
"Structura... | /Statslearningcourse/shiny_rCharts/test monthly/ui.R | no_license | amycook/cheatsheet | R | false | false | 2,370 | r |
# library('rHighcharts',lib='C:/Progra~1/R/R-3.2.0/library')
shinyUI(fluidPage(
titlePanel("Monthly Review"),
fluidRow(
column(3,
selectInput("disc", "Discipline:",
list("Civil" = "Civil",
"Structura... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mlp.R
\name{mlp}
\alias{MLP}
\alias{mlp}
\alias{mlp_classifier}
\alias{mlp_regressor}
\title{Multilayer perceptron}
\description{
Multilayer perceptron
}
\section{Usage}{
\preformatted{
mlp(output = 'sigm', hidden_sizes = 10, activation = 's... | /man/mlp.Rd | no_license | kota7/MLPipe | R | false | true | 3,399 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mlp.R
\name{mlp}
\alias{MLP}
\alias{mlp}
\alias{mlp_classifier}
\alias{mlp_regressor}
\title{Multilayer perceptron}
\description{
Multilayer perceptron
}
\section{Usage}{
\preformatted{
mlp(output = 'sigm', hidden_sizes = 10, activation = 's... |
################################################################################
#
# Hedonic evaluation
#
# Zachary Barkjohn, March 2019
#
################################################################################
# Import libraries
library(ggplot2)
library(GGally)
library(nnls)
# Read in data
dataH <- read.cs... | /HouseShopping/HedonicEvaluation.R | no_license | ZacharyBarker/Lazy-Sundays | R | false | false | 1,279 | r | ################################################################################
#
# Hedonic evaluation
#
# Zachary Barkjohn, March 2019
#
################################################################################
# Import libraries
library(ggplot2)
library(GGally)
library(nnls)
# Read in data
dataH <- read.cs... |
#' filter fimo_CTCF.
#'
#' @param dnase granges objects
#' @param fimo_GRanges ctcf_motif granges objects
#' @return filtered fimo GRanges objects
#' @importFrom GenomicRanges findOverlaps
#' @importFrom S4Vectors queryHits
#' @importFrom S4Vectors subjectHits
#' @export
#' @examples
#'
filter_fimo<-function(dnase,fim... | /R/filter_fimo_to_GRanges.R | no_license | caokai001/kcaoplot | R | false | false | 2,246 | r | #' filter fimo_CTCF.
#'
#' @param dnase granges objects
#' @param fimo_GRanges ctcf_motif granges objects
#' @return filtered fimo GRanges objects
#' @importFrom GenomicRanges findOverlaps
#' @importFrom S4Vectors queryHits
#' @importFrom S4Vectors subjectHits
#' @export
#' @examples
#'
filter_fimo<-function(dnase,fim... |
setClass("ADDCOL",
representation = representation(
strEqcCommand = "character",
rcdAddCol = "character",
colOut = "character",
blnOverwrite = "logical"
),
prototype = prototype(
strEqcCommand = "",
rcdAddCol = "",
colOut = "NewCol",
blnOve... | /EasyQC/R/clsADDCOL11.r | no_license | barbarathorslund/warfarin | R | false | false | 3,407 | r | setClass("ADDCOL",
representation = representation(
strEqcCommand = "character",
rcdAddCol = "character",
colOut = "character",
blnOverwrite = "logical"
),
prototype = prototype(
strEqcCommand = "",
rcdAddCol = "",
colOut = "NewCol",
blnOve... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/SlimFunctions.R
\name{reMap_mutations}
\alias{reMap_mutations}
\title{Re-map slim mutations}
\usage{
reMap_mutations(mutationDF, recomb_map)
}
\arguments{
\item{mutationDF}{The Mutation data frame returned by reMap_mutations}
\item{recomb_ma... | /man/reMap_mutations.Rd | no_license | simrvprojects/SimRVSequences | R | false | true | 468 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/SlimFunctions.R
\name{reMap_mutations}
\alias{reMap_mutations}
\title{Re-map slim mutations}
\usage{
reMap_mutations(mutationDF, recomb_map)
}
\arguments{
\item{mutationDF}{The Mutation data frame returned by reMap_mutations}
\item{recomb_ma... |
corr <- function(directory, threshold = 0){
tmp_cor <- c()
for (x in list.files(directory)){
pollution_data = read.csv(paste(sep = "",directory,"/",x))
numbers_rec = length((pollution_data[!is.na(pollution_data$nitrate) & !is.na(pollution_data$sulfate),]$sulfate))
if (numbers_rec > thres... | /corr.R | no_license | sacg45/datasciencecoursera | R | false | false | 625 | r | corr <- function(directory, threshold = 0){
tmp_cor <- c()
for (x in list.files(directory)){
pollution_data = read.csv(paste(sep = "",directory,"/",x))
numbers_rec = length((pollution_data[!is.na(pollution_data$nitrate) & !is.na(pollution_data$sulfate),]$sulfate))
if (numbers_rec > thres... |
get_asgmts_list <- function(template_id = NULL, # template id
qx_name = NULL, # questionnaire name
version = NULL, # version
responsible = "", # by default, find all
archived = FALSE, # by default, not archiv... | /get_asgmts_list.R | no_license | BECollymore/SuSoAPI | R | false | false | 6,908 | r | get_asgmts_list <- function(template_id = NULL, # template id
qx_name = NULL, # questionnaire name
version = NULL, # version
responsible = "", # by default, find all
archived = FALSE, # by default, not archiv... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generic.R
\name{summary.rmtfit}
\alias{summary.rmtfit}
\title{Summary of the analysis results}
\usage{
\method{summary}{rmtfit}(object, tau = NULL, Kmax = NULL, ...)
}
\arguments{
\item{object}{An object returned by \code{\link{rmtfit}}.}
\i... | /man/summary.rmtfit.Rd | no_license | cran/rmt | R | false | true | 1,413 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/generic.R
\name{summary.rmtfit}
\alias{summary.rmtfit}
\title{Summary of the analysis results}
\usage{
\method{summary}{rmtfit}(object, tau = NULL, Kmax = NULL, ...)
}
\arguments{
\item{object}{An object returned by \code{\link{rmtfit}}.}
\i... |
# You're free to implement the function my_mean however you want, as long as it
# returns the average of all of the numbers in `my_vector`.
#
# Hint #1: sum() returns the sum of a vector.
# Ex: sum(c(1, 2, 3)) evaluates to 6
#
# Hint #2: length() returns the size of a vector.
# Ex: length(c(1, 2, 3)) evaluates to 3
#... | /jhu/datascience/c1_R_Programming/week2/my_mean.R | no_license | hieudtrinh/coursera | R | false | false | 898 | r | # You're free to implement the function my_mean however you want, as long as it
# returns the average of all of the numbers in `my_vector`.
#
# Hint #1: sum() returns the sum of a vector.
# Ex: sum(c(1, 2, 3)) evaluates to 6
#
# Hint #2: length() returns the size of a vector.
# Ex: length(c(1, 2, 3)) evaluates to 3
#... |
#' Create the email message body
#'
#' The `compose_email()` function allows us to easily create an email message.
#' We can incorporate character vectors into the message body, the header, or
#' the footer.
#'
#' @param header,body,footer The three layout sections for an email message
#' (ordered from top to bottom)... | /R/compose_email.R | permissive | ASBecker/blastula | R | false | false | 2,905 | r | #' Create the email message body
#'
#' The `compose_email()` function allows us to easily create an email message.
#' We can incorporate character vectors into the message body, the header, or
#' the footer.
#'
#' @param header,body,footer The three layout sections for an email message
#' (ordered from top to bottom)... |
# Find the name associated with the pitcher ID in a dataframe and add the name in a column of that df.
add_pitcher_names <- function(df)
{
master <- read.csv("master.csv")
id_names <- master %>%
select(mlb_id, mlb_name) %>%
rename(pitcher = mlb_id)
new_df <- left_join(df, id_names, by = "pitcher") %>%
... | /Project 1 Combos/R_files/add_pitcher_names.r | no_license | ishaan91sethi/sabermetric-projects | R | false | false | 369 | r | # Find the name associated with the pitcher ID in a dataframe and add the name in a column of that df.
add_pitcher_names <- function(df)
{
master <- read.csv("master.csv")
id_names <- master %>%
select(mlb_id, mlb_name) %>%
rename(pitcher = mlb_id)
new_df <- left_join(df, id_names, by = "pitcher") %>%
... |
## Put comments here that give an overall description of what your
## functions do
## Write a short comment describing this function
# This function creates a list containing data matrix and its cached inverse
# furthermore the list contains setinv and getinv functions which
# set and return the calculated inverse
m... | /cachematrix.R | no_license | DSSfidd/ProgrammingAssignment2 | R | false | false | 1,008 | r | ## Put comments here that give an overall description of what your
## functions do
## Write a short comment describing this function
# This function creates a list containing data matrix and its cached inverse
# furthermore the list contains setinv and getinv functions which
# set and return the calculated inverse
m... |
#' Function to conduct region-based enrichment analysis using nearby gene annotations
#'
#' \code{xGRviaGeneAnno} is supposed to conduct region-based enrichment analysis for the input genomic region data (genome build h19), using nearby gene annotations. To do so, nearby genes are first defined within the maximum gap b... | /R/xGRviaGeneAnno.r | no_license | cran/XGR | R | false | false | 22,857 | r | #' Function to conduct region-based enrichment analysis using nearby gene annotations
#'
#' \code{xGRviaGeneAnno} is supposed to conduct region-based enrichment analysis for the input genomic region data (genome build h19), using nearby gene annotations. To do so, nearby genes are first defined within the maximum gap b... |
################################################################################
## vital_rate_ipm_fxns.R: This script contains functions for estimating
## growth, survival, and recruitment based on fitted vital rate functions and
## the current state of the population in the Integral Projection Model (IPM).
##
##
#... | /code/size_by_year_IPM/buffering_experiments/ipm_twostage_functions/ipm_vital_rate_fxns.R | permissive | atredennick/size-environment | R | false | false | 7,659 | r | ################################################################################
## vital_rate_ipm_fxns.R: This script contains functions for estimating
## growth, survival, and recruitment based on fitted vital rate functions and
## the current state of the population in the Integral Projection Model (IPM).
##
##
#... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/7_quick_double_enrich.R
\name{quick_enrich}
\alias{quick_enrich}
\title{quick_enrich}
\usage{
quick_enrich(genes, kkgo_file = "kkgo_file.Rdata", destdir = getwd())
}
\arguments{
\item{genes}{a gene symbol or entrizid vector}
\item{kkgo_file}... | /man/quick_enrich.Rd | permissive | lshilab/tinyarray | R | false | true | 735 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/7_quick_double_enrich.R
\name{quick_enrich}
\alias{quick_enrich}
\title{quick_enrich}
\usage{
quick_enrich(genes, kkgo_file = "kkgo_file.Rdata", destdir = getwd())
}
\arguments{
\item{genes}{a gene symbol or entrizid vector}
\item{kkgo_file}... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.