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 |
|---|---|---|---|---|---|---|---|---|---|
\name{lcy.NMF.cluster}
\alias{lcy.NMF.cluster}
\title{
cluster samples
}
\description{
Used to identify signature which best separates samples into given clusters. First nmf is used to decide cluster members and then sam, pam are used to identify optimal signature.
}
\usage{
lcy.NMF.cluster(d, clinic, rank = 3,... | /man/lcy.nmf.cluster.Rd | no_license | chengyu-liu-cs/lcyCF | R | false | false | 2,468 | rd | \name{lcy.NMF.cluster}
\alias{lcy.NMF.cluster}
\title{
cluster samples
}
\description{
Used to identify signature which best separates samples into given clusters. First nmf is used to decide cluster members and then sam, pam are used to identify optimal signature.
}
\usage{
lcy.NMF.cluster(d, clinic, rank = 3,... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/FunctionsForGenes.R
\name{kasa.duplicationRemovalBySD}
\alias{kasa.duplicationRemovalBySD}
\title{Duplicated value removal by SD}
\usage{
kasa.duplicationRemovalBySD(x)
}
\arguments{
\item{x}{input dataframe of gene matrix}
}
\value{
removed ... | /man/kasa.duplicationRemovalBySD.Rd | no_license | kasaha1/kasaBasicFunctions | R | false | true | 379 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/FunctionsForGenes.R
\name{kasa.duplicationRemovalBySD}
\alias{kasa.duplicationRemovalBySD}
\title{Duplicated value removal by SD}
\usage{
kasa.duplicationRemovalBySD(x)
}
\arguments{
\item{x}{input dataframe of gene matrix}
}
\value{
removed ... |
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... | /R/pkg/R/mllib_classification.R | permissive | Shopify/spark | R | false | false | 40,521 | r | #
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... |
library(tidyverse)
pouet<-tibble(x=c("philipe","Jean","maurice"),y=c(12,14,15))
pouet[1,]
library(readr)
etudiants<-read_csv2(file = "etudiants.csv",
locale = locale(
date_names ="fr",
decimal_mark=",",
encoding = "UTF-8",
... | /tp1.R | no_license | Amadoutall/tp_in_rstudio | R | false | false | 688 | r | library(tidyverse)
pouet<-tibble(x=c("philipe","Jean","maurice"),y=c(12,14,15))
pouet[1,]
library(readr)
etudiants<-read_csv2(file = "etudiants.csv",
locale = locale(
date_names ="fr",
decimal_mark=",",
encoding = "UTF-8",
... |
library(dplyr)
library(ggplot2)
library(pals)
library(mapdata)
theme_set(theme_bw())
reg = map_data("world2Hires")
reg = subset(reg, region %in% c('Canada', 'USA'))
reg$long = (360 - reg$long)*-1
#######
datavar = "MODISA" # "MODISA" or "OI"
#######
datasource = ""
# Region limits:
latlim = c(30,61.5)
lonlim = c(-160... | /scripts/NRT_SST_Plots_MODISA.R | no_license | cilori/Pacific_SST_NRT_Monitoring | R | false | false | 6,426 | r | library(dplyr)
library(ggplot2)
library(pals)
library(mapdata)
theme_set(theme_bw())
reg = map_data("world2Hires")
reg = subset(reg, region %in% c('Canada', 'USA'))
reg$long = (360 - reg$long)*-1
#######
datavar = "MODISA" # "MODISA" or "OI"
#######
datasource = ""
# Region limits:
latlim = c(30,61.5)
lonlim = c(-160... |
#Read data from file in working directory:
data <- read.table("household_power_consumption.txt",sep=";",colClasses=c("character","character","numeric",
"numeric","numeric","numeric","numeric","numeric","numeric"),header=TRUE, na.strings="?")
#Create logical vector for subsetting:
DatesOfInterest <... | /plot1.R | no_license | dkrooshof/ExData_Plotting1 | R | false | false | 669 | r | #Read data from file in working directory:
data <- read.table("household_power_consumption.txt",sep=";",colClasses=c("character","character","numeric",
"numeric","numeric","numeric","numeric","numeric","numeric"),header=TRUE, na.strings="?")
#Create logical vector for subsetting:
DatesOfInterest <... |
library(lmomco)
### Name: rlmomco
### Title: Random Variates of a Distribution
### Aliases: rlmomco
### Keywords: random variate quantile function The lmomco functions The
### lmomco function mimics of R nomenclature
### ** Examples
lmr <- lmoms(rnorm(20)) # generate 20 standard normal variates
para <- p... | /data/genthat_extracted_code/lmomco/examples/rlmomco.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 729 | r | library(lmomco)
### Name: rlmomco
### Title: Random Variates of a Distribution
### Aliases: rlmomco
### Keywords: random variate quantile function The lmomco functions The
### lmomco function mimics of R nomenclature
### ** Examples
lmr <- lmoms(rnorm(20)) # generate 20 standard normal variates
para <- p... |
# sort --- external sort of text lines
subroutine sort (ifd, ofd)
filedes ifd, ofd
define(MERGEORDER,7)
define(MERGETEXT,900)
define(NAMESIZE,30)
define(MAXTEXT,32768)
define(MAXPTR,4096)
define(LOGPTR,12)
character linbuf (MAXTEXT), name (NAMESIZE)
integer infil (MERGEORDER), linptr (M... | /swt/src/spc/xref.u/xref_sort.r | no_license | arnoldrobbins/gt-swt | R | false | false | 7,193 | r | # sort --- external sort of text lines
subroutine sort (ifd, ofd)
filedes ifd, ofd
define(MERGEORDER,7)
define(MERGETEXT,900)
define(NAMESIZE,30)
define(MAXTEXT,32768)
define(MAXPTR,4096)
define(LOGPTR,12)
character linbuf (MAXTEXT), name (NAMESIZE)
integer infil (MERGEORDER), linptr (M... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/includeTaxa.R
\name{includeTaxa}
\alias{includeTaxa}
\title{Includes the list of taxa into the reconstructions.}
\usage{
includeTaxa(x, taxa, climate)
}
\arguments{
\item{x}{A \code{\link{crestObj}} produced by one of the \code{\link{crest}},... | /man/includeTaxa.Rd | permissive | mchevalier2/crestr | R | false | true | 962 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/includeTaxa.R
\name{includeTaxa}
\alias{includeTaxa}
\title{Includes the list of taxa into the reconstructions.}
\usage{
includeTaxa(x, taxa, climate)
}
\arguments{
\item{x}{A \code{\link{crestObj}} produced by one of the \code{\link{crest}},... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/caching.R
\name{save.object}
\alias{save.object}
\title{Save an object (cache)}
\usage{
save.object(o, name = NULL, cache.dir)
}
\arguments{
\item{o}{object to save}
}
\value{
nothing
}
\description{
Save an object (cache)
}
\examples{
save.o... | /man/save.object.Rd | permissive | pydupont/cacheR | R | false | true | 334 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/caching.R
\name{save.object}
\alias{save.object}
\title{Save an object (cache)}
\usage{
save.object(o, name = NULL, cache.dir)
}
\arguments{
\item{o}{object to save}
}
\value{
nothing
}
\description{
Save an object (cache)
}
\examples{
save.o... |
#' @export
emphasis.app <- function() {
appDir <- system.file("Shiny-examples", "emphasis_postprocessing.R", package = "emphasis")
if (appDir == "") {
stop("Could not find example directory. Try re-installing `emphasis`.", call. = FALSE)
}
shiny::runApp(appDir, display.mode = "normal")
}
#' @export
ana... | /R/Emphasis_dd.R | no_license | thijsjanzen/emphasis | R | false | false | 601 | r | #' @export
emphasis.app <- function() {
appDir <- system.file("Shiny-examples", "emphasis_postprocessing.R", package = "emphasis")
if (appDir == "") {
stop("Could not find example directory. Try re-installing `emphasis`.", call. = FALSE)
}
shiny::runApp(appDir, display.mode = "normal")
}
#' @export
ana... |
#' South Dakota Sales Tax
#'
#' Takes any value that is inputted and multiples it by the South Dakota Sales Tax
#' @param x is the value before sales tax
#' @return total with sales tax
#' @export
SD_sales <- function(x)
{
total <- (x * 0.045) + x
return(total)
}
| /SalesTax/R/Sotuh Dakota.R | no_license | ddang4370/Final-Project | R | false | false | 268 | r | #' South Dakota Sales Tax
#'
#' Takes any value that is inputted and multiples it by the South Dakota Sales Tax
#' @param x is the value before sales tax
#' @return total with sales tax
#' @export
SD_sales <- function(x)
{
total <- (x * 0.045) + x
return(total)
}
|
## ----eval=FALSE, echo=TRUE, tidy=FALSE, size='footnotesize'--------------
# N.pla <- 1900
# N.vax <- 1700
# aveVElist <- list(-2, -1.5, -1, -0.5, 0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, c(0,0), c(0.4,0),
# c(0.4,0.4), c(0.4,0.2), c(0.4,0.3), c(0.5,0.3), c(0.5,0.4), c(0.6,0.3), c(0.6,0.4))... | /inst/doc/seqDesignInstructions.R | no_license | cran/seqDesign | R | false | false | 3,457 | r | ## ----eval=FALSE, echo=TRUE, tidy=FALSE, size='footnotesize'--------------
# N.pla <- 1900
# N.vax <- 1700
# aveVElist <- list(-2, -1.5, -1, -0.5, 0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, c(0,0), c(0.4,0),
# c(0.4,0.4), c(0.4,0.2), c(0.4,0.3), c(0.5,0.3), c(0.5,0.4), c(0.6,0.3), c(0.6,0.4))... |
# Create the documentation for the package
devtools::document()
# Install the package
devtools::install(force = TRUE)
# Build the pkgdown site
# pkgdown::build_site()
# Check package
devtools::check()
# Load the package and view the summary
library(conjointTools)
help(package = 'conjointTools')
# Install from gith... | /build.R | permissive | jrwhelan/conjointTools | R | false | false | 374 | r | # Create the documentation for the package
devtools::document()
# Install the package
devtools::install(force = TRUE)
# Build the pkgdown site
# pkgdown::build_site()
# Check package
devtools::check()
# Load the package and view the summary
library(conjointTools)
help(package = 'conjointTools')
# Install from gith... |
library(tree)
library(randomForest)
library(gbm)
#Carseat Sales data set.
#Created test and train sets that are 50% of the data each.
#Also created a variable that is assigned to the true Sales values, true.vals, from the test set.
seed.val<-12345
set.seed(seed.val)
carseat.df <- read.csv("/Users/ryancoulter/Des... | /SalesProject.R | no_license | RyanHCoulter/PersonalDataAnalysisProjects | R | false | false | 3,527 | r |
library(tree)
library(randomForest)
library(gbm)
#Carseat Sales data set.
#Created test and train sets that are 50% of the data each.
#Also created a variable that is assigned to the true Sales values, true.vals, from the test set.
seed.val<-12345
set.seed(seed.val)
carseat.df <- read.csv("/Users/ryancoulter/Des... |
#' Butcher methods for a workflow
#'
#' These methods allow you to use the butcher package to reduce the size of
#' a workflow. After calling `butcher::butcher()` on a workflow, the only
#' guarantee is that you will still be able to `predict()` from that workflow.
#' Other functions may not work as expected.
#'
#' @pa... | /R/butcher.R | permissive | dkgaraujo/workflows | R | false | false | 4,816 | r | #' Butcher methods for a workflow
#'
#' These methods allow you to use the butcher package to reduce the size of
#' a workflow. After calling `butcher::butcher()` on a workflow, the only
#' guarantee is that you will still be able to `predict()` from that workflow.
#' Other functions may not work as expected.
#'
#' @pa... |
library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/AvgRank/NSCLC.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.8,family="gaussian",standardize=FALSE)
sink('./NSCLC_082.txt',append=TRUE)
print... | /Model/EN/AvgRank/NSCLC/NSCLC_082.R | no_license | esbgkannan/QSMART | R | false | false | 344 | r | library(glmnet)
mydata = read.table("../../../../TrainingSet/FullSet/AvgRank/NSCLC.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.8,family="gaussian",standardize=FALSE)
sink('./NSCLC_082.txt',append=TRUE)
print... |
#!/hpf/tools/centos6/R/3.1.1/bin/Rscript
if (length(commandArgs(TRUE))<5){print("Error: incorrect number of arguments");if(NA)print("Error");}
path=commandArgs(TRUE)[1];
datapath=commandArgs(TRUE)[2];
resultdir=commandArgs(TRUE)[3];
if (length(commandArgs(TRUE))>3 && !(commandArgs(TRUE)[4] %in% c("0","1"))){exprfile=co... | /diseaseMechanism/Rproject/analyse_data.r~ | no_license | goldenberg-lab/nc_aggregation | R | false | false | 14,023 | #!/hpf/tools/centos6/R/3.1.1/bin/Rscript
if (length(commandArgs(TRUE))<5){print("Error: incorrect number of arguments");if(NA)print("Error");}
path=commandArgs(TRUE)[1];
datapath=commandArgs(TRUE)[2];
resultdir=commandArgs(TRUE)[3];
if (length(commandArgs(TRUE))>3 && !(commandArgs(TRUE)[4] %in% c("0","1"))){exprfile=co... | |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/binomialfunction.R
\name{bin_cumulative}
\alias{bin_cumulative}
\title{Binomal cumulative}
\usage{
bin_cumulative(n, p)
}
\arguments{
\item{n}{the number of trials}
\item{p}{the probability of successes}
}
\value{
create a data frame of cumi... | /binomial/man/bin_cumulative.Rd | no_license | stat133-sp19/hw-stat133-lynn0707 | R | false | true | 753 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/binomialfunction.R
\name{bin_cumulative}
\alias{bin_cumulative}
\title{Binomal cumulative}
\usage{
bin_cumulative(n, p)
}
\arguments{
\item{n}{the number of trials}
\item{p}{the probability of successes}
}
\value{
create a data frame of cumi... |
#
# Plots MDS timeseries
#
source("plot//plotTimeseries.R")
source("plot//plotDendrogram.R")
plotDendrogramTimeseries = function(hclustSeries, labels=NULL, category=NULL,
timeLabels=NULL, timeLabelOffset=1, maxHeight=1,
...) {
# TODO: implem... | /plot/plotDendrogramTimeseries.R | permissive | blairkan/RConfMatrixPlots | R | false | false | 512 | r | #
# Plots MDS timeseries
#
source("plot//plotTimeseries.R")
source("plot//plotDendrogram.R")
plotDendrogramTimeseries = function(hclustSeries, labels=NULL, category=NULL,
timeLabels=NULL, timeLabelOffset=1, maxHeight=1,
...) {
# TODO: implem... |
# Script to extract monthly output from ED and put it into a netcdf
path.base <- '/projectnb/dietzelab/paleon/ED_runs/MIP2_Region'
source(file.path(path.base, "0_setup", "model2netcdf.ED2.paleon.R"), chdir = TRUE)
site='lat45.25lon-68.75'
sitelat <- as.numeric(substr(site,4,8)) # lat from SAS run
sitelon <- as.num... | /ED_Workflow/3_spin_finish/spinfinish_qaqc.v1/lat45.25lon-68.75/extract_output_general.R | no_license | MortonArb-ForestEcology/URF2018-Butkiewicz | R | false | false | 1,920 | r | # Script to extract monthly output from ED and put it into a netcdf
path.base <- '/projectnb/dietzelab/paleon/ED_runs/MIP2_Region'
source(file.path(path.base, "0_setup", "model2netcdf.ED2.paleon.R"), chdir = TRUE)
site='lat45.25lon-68.75'
sitelat <- as.numeric(substr(site,4,8)) # lat from SAS run
sitelon <- as.num... |
#### author: Jinlong Zhang <jinlongzhang01@gmail.com>
#### institution: Kadoorie Farm and Botanic Garden, Hong Kong
#### package: phylotools
#### URL: http://github.com/helixcn/phylotools
#### date: 26 MAY 2015
get.phylip.name <- function(infile, clean_name = FALSE){
dat <- read.phylip(infile, clean_name = clean_... | /R/get.phylip.name.R | no_license | lzhangss/phylotools | R | false | false | 350 | r | #### author: Jinlong Zhang <jinlongzhang01@gmail.com>
#### institution: Kadoorie Farm and Botanic Garden, Hong Kong
#### package: phylotools
#### URL: http://github.com/helixcn/phylotools
#### date: 26 MAY 2015
get.phylip.name <- function(infile, clean_name = FALSE){
dat <- read.phylip(infile, clean_name = clean_... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lvl0_UCD.R
\name{lvl0_loadUCD}
\alias{lvl0_loadUCD}
\title{Load the UCD transportation database}
\usage{
lvl0_loadUCD(GCAM_data, EDGE_scenario, REMIND_scenario, input_folder,
years, UCD_dir = "UCD")
}
\arguments{
\item{UCD_dir}{}
}
\descrip... | /man/lvl0_loadUCD.Rd | no_license | SebastianFra/edgeTransport | R | false | true | 581 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lvl0_UCD.R
\name{lvl0_loadUCD}
\alias{lvl0_loadUCD}
\title{Load the UCD transportation database}
\usage{
lvl0_loadUCD(GCAM_data, EDGE_scenario, REMIND_scenario, input_folder,
years, UCD_dir = "UCD")
}
\arguments{
\item{UCD_dir}{}
}
\descrip... |
\name{NISTcalthPerCmSecDegCtOwattPerMeterK}
\alias{NISTcalthPerCmSecDegCtOwattPerMeterK}
\title{Convert calorieth per centimeter second degree Celsius to watt per meter kelvin }
\usage{NISTcalthPerCmSecDegCtOwattPerMeterK(calthPerCmSecDegC)}
\description{\code{NISTcalthPerCmSecDegCtOwattPerMeterK} converts from calori... | /man/NISTcalthPerCmSecDegCtOwattPerMeterK.Rd | no_license | cran/NISTunits | R | false | false | 1,057 | rd | \name{NISTcalthPerCmSecDegCtOwattPerMeterK}
\alias{NISTcalthPerCmSecDegCtOwattPerMeterK}
\title{Convert calorieth per centimeter second degree Celsius to watt per meter kelvin }
\usage{NISTcalthPerCmSecDegCtOwattPerMeterK(calthPerCmSecDegC)}
\description{\code{NISTcalthPerCmSecDegCtOwattPerMeterK} converts from calori... |
\name{bal.tab.Match}
\alias{bal.tab.Match}
\alias{bal.tab.optmatch}
\alias{bal.tab.ebalance}
\alias{bal.tab.designmatch}
\title{
Balance Statistics for \code{Matching}, \code{optmatch}, \code{ebal}, and \code{designmatch} Objects
}
\description{
Generates balance statistics for output objects from \pkg{Matching}, \pkg... | /man/bal.tab.Match.Rd | no_license | guhjy/cobalt | R | false | false | 10,669 | rd | \name{bal.tab.Match}
\alias{bal.tab.Match}
\alias{bal.tab.optmatch}
\alias{bal.tab.ebalance}
\alias{bal.tab.designmatch}
\title{
Balance Statistics for \code{Matching}, \code{optmatch}, \code{ebal}, and \code{designmatch} Objects
}
\description{
Generates balance statistics for output objects from \pkg{Matching}, \pkg... |
#' Plot Method for the train Class
#'
#' This function takes the output of a \code{\link{train}} object and creates a
#' line or level plot using the \pkg{lattice} or \pkg{ggplot2} libraries.
#'
#' If there are no tuning parameters, or none were varied, an error is
#' produced.
#'
#' If the model has one tuning para... | /pkg/caret/R/plot.train.R | no_license | mutual-ai/caret | R | false | false | 11,852 | r | #' Plot Method for the train Class
#'
#' This function takes the output of a \code{\link{train}} object and creates a
#' line or level plot using the \pkg{lattice} or \pkg{ggplot2} libraries.
#'
#' If there are no tuning parameters, or none were varied, an error is
#' produced.
#'
#' If the model has one tuning para... |
# MethylMix analysis of pancreatic cancer dataset
# Since there are no normal samples, we just want the trancriptionally predictive genes. These can be obtained using
# MethylMix_ModelGeneExpression
library(MethylMix)
library(doParallel)
library(tictoc)
rm(list=ls())
# load data
load("/home/anita/Benchmarking/two_om... | /Multi-staged tools/PancreaticCancer/MethylMix/MethylMix_PAAD_Analysis.R | no_license | AtinaSat/Evaluation-of-integration-tools | R | false | false | 1,841 | r | # MethylMix analysis of pancreatic cancer dataset
# Since there are no normal samples, we just want the trancriptionally predictive genes. These can be obtained using
# MethylMix_ModelGeneExpression
library(MethylMix)
library(doParallel)
library(tictoc)
rm(list=ls())
# load data
load("/home/anita/Benchmarking/two_om... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/eif_moderated.R
\name{modtest_ic}
\alias{modtest_ic}
\title{Moderated Statistical Tests for Influence Functions}
\usage{
modtest_ic(biotmle, adjust = "BH", pval_type = c("normal", "logistic"), ...)
}
\arguments{
\item{biotmle}{\code{biotmle} ... | /man/modtest_ic.Rd | permissive | nhejazi/biotmle | R | false | true | 2,006 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/eif_moderated.R
\name{modtest_ic}
\alias{modtest_ic}
\title{Moderated Statistical Tests for Influence Functions}
\usage{
modtest_ic(biotmle, adjust = "BH", pval_type = c("normal", "logistic"), ...)
}
\arguments{
\item{biotmle}{\code{biotmle} ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rl_generate_policy.R
\name{rl_generate_policy}
\alias{rl_generate_policy}
\title{Function performs Reinforcement Learning using the past data to generate model policy}
\usage{
rl_generate_policy(x, states, actions, control)
}
\arguments{
\ite... | /man/rl_generate_policy.Rd | permissive | Soyouzzz1986/lazytrade | R | false | true | 1,562 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rl_generate_policy.R
\name{rl_generate_policy}
\alias{rl_generate_policy}
\title{Function performs Reinforcement Learning using the past data to generate model policy}
\usage{
rl_generate_policy(x, states, actions, control)
}
\arguments{
\ite... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fitRSF.R
\name{fitRSF}
\alias{fitRSF}
\title{Fit RSF}
\usage{
fitRSF(xy, method = c("poisson", "logit"), covlist, nbin = NULL,
nzeros = NULL, buffsize = NULL)
}
\arguments{
\item{xy}{Matrix of observed locations}
\item{method}{Method to fi... | /man/fitRSF.Rd | no_license | TheoMichelot/localGibbs | R | false | true | 826 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fitRSF.R
\name{fitRSF}
\alias{fitRSF}
\title{Fit RSF}
\usage{
fitRSF(xy, method = c("poisson", "logit"), covlist, nbin = NULL,
nzeros = NULL, buffsize = NULL)
}
\arguments{
\item{xy}{Matrix of observed locations}
\item{method}{Method to fi... |
library(shiny)
# Define UI for dataset viewer application
shinyUI(fluidPage(
# Application title
titlePanel("Data Science Specilization Rating"),
br(),
sidebarLayout(
sidebarPanel(
textInput("fname", "First Name:", "Enter your first name"),
textInput("lname", "Last Name:", "Enter your Last ... | /ui.r | no_license | ritesh256/ShinyCourseProjectApp | R | false | false | 1,234 | r | library(shiny)
# Define UI for dataset viewer application
shinyUI(fluidPage(
# Application title
titlePanel("Data Science Specilization Rating"),
br(),
sidebarLayout(
sidebarPanel(
textInput("fname", "First Name:", "Enter your first name"),
textInput("lname", "Last Name:", "Enter your Last ... |
# -------------------#
# NO2 atlas workflow #
# -------------------#
# The workflow consists of the following steps
# 1) Looking up which OTM shape files are needed to construct a shape file of the domain
# and producue the shape file. By default the city centre (defined in city.df) is taken
# as the cent... | /NO2_atlas_workflow.R | permissive | bd77/SHERPA-city | R | false | false | 14,960 | r | # -------------------#
# NO2 atlas workflow #
# -------------------#
# The workflow consists of the following steps
# 1) Looking up which OTM shape files are needed to construct a shape file of the domain
# and producue the shape file. By default the city centre (defined in city.df) is taken
# as the cent... |
# 1. Directories and names -----------------------------------------------
# file directory koppeltabel. NB: zorg dat sheetname='AGV', kolommen= 'CODE', 'balansnaam', 'agrarisch'
dir_kop <- 'pbelasting/input/190324_koppeltabel.xlsx'
# folder directory waterbalansen NB: zorg dat alle foute balansen niet in deze dir ... | /scripts/loadBalances.R | no_license | gerardhros/WaternetAnalyse | R | false | false | 10,268 | r | # 1. Directories and names -----------------------------------------------
# file directory koppeltabel. NB: zorg dat sheetname='AGV', kolommen= 'CODE', 'balansnaam', 'agrarisch'
dir_kop <- 'pbelasting/input/190324_koppeltabel.xlsx'
# folder directory waterbalansen NB: zorg dat alle foute balansen niet in deze dir ... |
## ============================================================================
## Exploratory Data Analysis
## ============================================================================
## Course Project 1 - Electric Power Consumption
## Plot 2
## ---------------------------------------------------------------------... | /plot2.R | no_license | PhilippDBC/ExData_Plotting1 | R | false | false | 1,604 | r | ## ============================================================================
## Exploratory Data Analysis
## ============================================================================
## Course Project 1 - Electric Power Consumption
## Plot 2
## ---------------------------------------------------------------------... |
######################################################################################
## Figures for Green's function model paper
######################################################################################
# cols<-c('#d7191c','#fdae61','#ffffbf','#abd9e9','#2c7bb6')
cols<-c('#ca0020','#f4a582','#f7f7f7','#9... | /figures.R | no_license | sjpeacock/Spatiotemporal-infection-model | R | false | false | 21,396 | r | ######################################################################################
## Figures for Green's function model paper
######################################################################################
# cols<-c('#d7191c','#fdae61','#ffffbf','#abd9e9','#2c7bb6')
cols<-c('#ca0020','#f4a582','#f7f7f7','#9... |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do not modify this file since it was automatically generated from:
%
% plot-methods.R
%
% by the Rdoc compiler part of the R.oo package.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\name{noisePlot}
\alias{noi... | /man/noisePlot.Rd | no_license | ccagc/QDNAseq | R | false | false | 962 | rd | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do not modify this file since it was automatically generated from:
%
% plot-methods.R
%
% by the Rdoc compiler part of the R.oo package.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\name{noisePlot}
\alias{noi... |
# 09. 데이터 분석 프로젝트
# 09-1. '한국복지패널데이터' 분석 준비하기
install.packages("foreign") # foreign 패키지 설치
install.packages("dplyr")
install.packages("ggplot2")
install.packages("readxl")
library(foreign) # SPSS 파일 로드
library(dplyr) # 전처리
library(ggplot2) # 시각화
library(readxl) # 엑셀 파일 불러오기
raw_welfare <- read.spss(fi... | /코드 - 2015년도 한국인의 삶 비교분석.R | no_license | wnsqja1324/R_report | R | false | false | 11,069 | r | # 09. 데이터 분석 프로젝트
# 09-1. '한국복지패널데이터' 분석 준비하기
install.packages("foreign") # foreign 패키지 설치
install.packages("dplyr")
install.packages("ggplot2")
install.packages("readxl")
library(foreign) # SPSS 파일 로드
library(dplyr) # 전처리
library(ggplot2) # 시각화
library(readxl) # 엑셀 파일 불러오기
raw_welfare <- read.spss(fi... |
# Copyright (C) 2010-$year$ - Sebastien Bihorel
#
# This file must be used under the terms of the CeCILL.
# This source file is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
# are also available at
# http://www.cecill.info/licences/Licence_CeCILL_V2-... | /R/as.R | no_license | sbihorel/optimbase | R | false | false | 582 | r | # Copyright (C) 2010-$year$ - Sebastien Bihorel
#
# This file must be used under the terms of the CeCILL.
# This source file is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
# are also available at
# http://www.cecill.info/licences/Licence_CeCILL_V2-... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fingerprint_tools.R
\name{setdiff_fingerprints}
\alias{setdiff_fingerprints}
\title{Calcualte the set-difference for two sets of fingerprints elementwise}
\usage{
setdiff_fingerprints(fps_A, fps_B)
}
\arguments{
\item{fps_A}{fps list of \code... | /man/setdiff_fingerprints.Rd | permissive | bachi55/rcdkTools | R | false | true | 1,256 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fingerprint_tools.R
\name{setdiff_fingerprints}
\alias{setdiff_fingerprints}
\title{Calcualte the set-difference for two sets of fingerprints elementwise}
\usage{
setdiff_fingerprints(fps_A, fps_B)
}
\arguments{
\item{fps_A}{fps list of \code... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/model.R
\name{predict_proba}
\alias{predict_proba}
\alias{predict_classes}
\title{Generates probability or class probability predictions for the input samples.}
\usage{
predict_proba(object, x, batch_size = NULL, verbose = 0, steps = NULL)
p... | /man/predict_proba.Rd | no_license | lurd4862/keras | R | false | true | 1,545 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/model.R
\name{predict_proba}
\alias{predict_proba}
\alias{predict_classes}
\title{Generates probability or class probability predictions for the input samples.}
\usage{
predict_proba(object, x, batch_size = NULL, verbose = 0, steps = NULL)
p... |
shinyServer(function(input, output, session) {
shiny::observeEvent(c(input$run),{
output$plot <- shiny::renderPlot({
ext_status_plot(data()(),stat = input$panel)
})
})
data <- shiny::eventReactive(input$run,{
shiny::reactivePoll(
1000, session,
# This function returns the t... | /server.R | no_license | yonicd/NMTracker | R | false | false | 1,143 | r | shinyServer(function(input, output, session) {
shiny::observeEvent(c(input$run),{
output$plot <- shiny::renderPlot({
ext_status_plot(data()(),stat = input$panel)
})
})
data <- shiny::eventReactive(input$run,{
shiny::reactivePoll(
1000, session,
# This function returns the t... |
# Copyright (c) 2018 by Einzbern
# 目的1:计算 "不需要发发了” 与 "需要发发了" 两类从发业绩预告开始之后一年的市场表现
# 目的2:计算以定期报告为t=0,从t=-100天开始算到t=50天的CAR
#####----Guidance----#####
load("../Output/02-D-Trading-Data.RData")
options(scipen = 99, digits = 3)
library(tidyverse)
library(lubridate)
library(moments)
library(xlsx)
library(stargazer)
#####... | /04-C-CAR.R | no_license | ssh352/Earnings-Guidance | R | false | false | 11,444 | r | # Copyright (c) 2018 by Einzbern
# 目的1:计算 "不需要发发了” 与 "需要发发了" 两类从发业绩预告开始之后一年的市场表现
# 目的2:计算以定期报告为t=0,从t=-100天开始算到t=50天的CAR
#####----Guidance----#####
load("../Output/02-D-Trading-Data.RData")
options(scipen = 99, digits = 3)
library(tidyverse)
library(lubridate)
library(moments)
library(xlsx)
library(stargazer)
#####... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/xgb.model.dt.tree.R
\name{xgb.model.dt.tree}
\alias{xgb.model.dt.tree}
\title{Parse a boosted tree model text dump}
\usage{
xgb.model.dt.tree(feature_names = NULL, model = NULL, text = NULL,
n_first_tree = NULL)
}
\arguments{
\item{feature_... | /R-package/man/xgb.model.dt.tree.Rd | permissive | zoucuomiao/xgboost | R | false | true | 2,352 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/xgb.model.dt.tree.R
\name{xgb.model.dt.tree}
\alias{xgb.model.dt.tree}
\title{Parse a boosted tree model text dump}
\usage{
xgb.model.dt.tree(feature_names = NULL, model = NULL, text = NULL,
n_first_tree = NULL)
}
\arguments{
\item{feature_... |
if(!exists('girix.input')) {
source("/home/ubuntu/i2b2/GIRIXScripts/lib/girix.r")
setwd("ReportGenerator")
girix.input['params'] <- '{}'
girix.input['Patient set'] <- '-1'
girix.input["requestDiagram"] <- 'all'
}
source("ReportGen/main.r", local=T)
input <- girix.input
girix.output[["Report"]] <- generateOu... | /GIRIXScripts/ReportGenerator/mainscript.r | no_license | bp2014n2/i2b2 | R | false | false | 456 | r | if(!exists('girix.input')) {
source("/home/ubuntu/i2b2/GIRIXScripts/lib/girix.r")
setwd("ReportGenerator")
girix.input['params'] <- '{}'
girix.input['Patient set'] <- '-1'
girix.input["requestDiagram"] <- 'all'
}
source("ReportGen/main.r", local=T)
input <- girix.input
girix.output[["Report"]] <- generateOu... |
library("audio")
piano_frequency <- function(n){
return((2^(1/12))^(n-49)*440)
}
piano_keys = c(1:88)
frequencies <- piano_frequency(piano_keys)
durations <- rep(1/12,88)
piano_frame <- data.frame(freq = frequencies,duration = durations)
tempo <- 120
sample_rate <- 44100
make_sine <- function(freq, duration) {
... | /Data Science Internship/music.R | no_license | AaronKruchten/PSC-EDA | R | false | false | 937 | r | library("audio")
piano_frequency <- function(n){
return((2^(1/12))^(n-49)*440)
}
piano_keys = c(1:88)
frequencies <- piano_frequency(piano_keys)
durations <- rep(1/12,88)
piano_frame <- data.frame(freq = frequencies,duration = durations)
tempo <- 120
sample_rate <- 44100
make_sine <- function(freq, duration) {
... |
#' hm
#'
#' This function draws heatmap of HiC data so that we can visually compares the imputation results.
#'
#' @param datvec A vector of upper triangular mamtrix.
#' @param n Number of bins.
#' @param title The title of the heatmap.
#'
#' @return Heatmap of the matrix.
#' @export
#'
#' @examples.
#' data("K562_1_t... | /R/hm.R | no_license | Queen0044/scHiCBayes | R | false | false | 765 | r | #' hm
#'
#' This function draws heatmap of HiC data so that we can visually compares the imputation results.
#'
#' @param datvec A vector of upper triangular mamtrix.
#' @param n Number of bins.
#' @param title The title of the heatmap.
#'
#' @return Heatmap of the matrix.
#' @export
#'
#' @examples.
#' data("K562_1_t... |
# read data from txt file
data <- read.table("household_power_consumption.txt"
, header = TRUE, sep=";"
, stringsAsFactors = FALSE
, na.strings = "?")
# select only required subdata
sub_data <- data[data$Date == "1/2/2007"
| data$Date == "2/2/2... | /plot3.R | no_license | DaanHoevers/ExData_Plotting1 | R | false | false | 1,055 | r | # read data from txt file
data <- read.table("household_power_consumption.txt"
, header = TRUE, sep=";"
, stringsAsFactors = FALSE
, na.strings = "?")
# select only required subdata
sub_data <- data[data$Date == "1/2/2007"
| data$Date == "2/2/2... |
library(concordance)
### Name: concordance
### Title: concord
### Aliases: concord
### Keywords: concordance
### ** Examples
## data(concord_data, package="concordance")
codes.of.origin <- concord_data$isic2 # Vector of values to be converted
concord(codes.of.origin, "isic2", "sitc4")
concord("00121", "sitc3", "hs... | /data/genthat_extracted_code/concordance/examples/concord.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 1,591 | r | library(concordance)
### Name: concordance
### Title: concord
### Aliases: concord
### Keywords: concordance
### ** Examples
## data(concord_data, package="concordance")
codes.of.origin <- concord_data$isic2 # Vector of values to be converted
concord(codes.of.origin, "isic2", "sitc4")
concord("00121", "sitc3", "hs... |
library(gdata)
### Name: elem
### Title: Display Information about Elements in a Given Object
### Aliases: elem
### Keywords: attribute classes list print utilities
### ** Examples
## Not run:
##D data(infert)
##D elem(infert)
##D model <- glm(case~spontaneous+induced, family=binomial, data=infert)
##D elem(model,... | /data/genthat_extracted_code/gdata/examples/elem.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 373 | r | library(gdata)
### Name: elem
### Title: Display Information about Elements in a Given Object
### Aliases: elem
### Keywords: attribute classes list print utilities
### ** Examples
## Not run:
##D data(infert)
##D elem(infert)
##D model <- glm(case~spontaneous+induced, family=binomial, data=infert)
##D elem(model,... |
###
# training skeleton
###
library(caret)
# add any model specific package library commands
# set working directory
WORK.DIR <- "./src/skeleton_model" # modify to specify directory to contain model artififacts
# Common Functions and Global variables
source("./src/CommonFunctions.R")
source(paste0(WORK.DIR,"/ModelC... | /src/xgb_model/train_model.R | no_license | jimthompson5802/kaggle-OttoGroup | R | false | false | 4,052 | r | ###
# training skeleton
###
library(caret)
# add any model specific package library commands
# set working directory
WORK.DIR <- "./src/skeleton_model" # modify to specify directory to contain model artififacts
# Common Functions and Global variables
source("./src/CommonFunctions.R")
source(paste0(WORK.DIR,"/ModelC... |
######################### Tidy data output ##################################
# Groups the meanstd_data file by subject ID and Activity and takes the average
tidy_output <-
meanstd_data %>%
select(-meas_source) %>% # Remove measure
group_by(subjectID, Activity) %>%
summariz... | /03_Getting_And_Cleaning_Data/06_tidy_output.R | no_license | kartik-avula/Assignments | R | false | false | 335 | r | ######################### Tidy data output ##################################
# Groups the meanstd_data file by subject ID and Activity and takes the average
tidy_output <-
meanstd_data %>%
select(-meas_source) %>% # Remove measure
group_by(subjectID, Activity) %>%
summariz... |
path="D:/Pro ML book/Code files/Random forest/Files"
setwd(path)
t=read.csv("train_sample.csv")
train=t[1:8000,]
test=t[8001:9999,]
library(rpart)
test$prediction=0
for(i in 1:1000){ # we are running 1000 times - i.e., 1000 decision trees
y=0.5
x=sample(1:nrow(t),round(nrow(t)*y)) # Sample 50% of total ... | /Chapter 5 - Random Forest/rf_code.R | no_license | marcusdipaula/Pro-Machine-Learning | R | false | false | 806 | r | path="D:/Pro ML book/Code files/Random forest/Files"
setwd(path)
t=read.csv("train_sample.csv")
train=t[1:8000,]
test=t[8001:9999,]
library(rpart)
test$prediction=0
for(i in 1:1000){ # we are running 1000 times - i.e., 1000 decision trees
y=0.5
x=sample(1:nrow(t),round(nrow(t)*y)) # Sample 50% of total ... |
# ADOBE CONFIDENTIAL
# ___________________
# Copyright 2018 Adobe Systems Incorporated
# All Rights Reserved.
# NOTICE: All information contained herein is, and remains
# the property of Adobe Systems Incorporated and its suppliers,
# if any. The intellectual and technical concepts contained
# herein are proprietary to... | /recipes/R/Retail - GradientBoosting/R/applicationScorer.R | permissive | paulhsiung/experience-platform-dsw-reference | R | false | false | 4,624 | r | # ADOBE CONFIDENTIAL
# ___________________
# Copyright 2018 Adobe Systems Incorporated
# All Rights Reserved.
# NOTICE: All information contained herein is, and remains
# the property of Adobe Systems Incorporated and its suppliers,
# if any. The intellectual and technical concepts contained
# herein are proprietary to... |
############################################
#Variance inflation factor function for LME#
############################################
vif.lme <- function (fit) {
## adapted from rms::vif
v <- vcov(fit)
if(class(fit)=="lme"){
nam <- names(fixef(fit))
}else{
nam <- names(coef(fit))
}
## exclude inte... | /Functions for Multilevel RCM/vif_lme.R | permissive | Thvb/R-function-lib | R | false | false | 547 | r | ############################################
#Variance inflation factor function for LME#
############################################
vif.lme <- function (fit) {
## adapted from rms::vif
v <- vcov(fit)
if(class(fit)=="lme"){
nam <- names(fixef(fit))
}else{
nam <- names(coef(fit))
}
## exclude inte... |
## Sandwich estimator for variance of RR
var.rr.dr = function(y, x, va, vb, vc, alpha.dr, alpha.ml, beta.ml, gamma,
optimal, weights) {
########################################
pscore = as.vector(expit(vc %*% gamma))
n = length(pscore)
### 1. - E[dS/d(alpha.ml,beta.ml)] #####... | /R/2.2_DR_Var_RR.R | no_license | mclements/brm | R | false | false | 4,013 | r |
## Sandwich estimator for variance of RR
var.rr.dr = function(y, x, va, vb, vc, alpha.dr, alpha.ml, beta.ml, gamma,
optimal, weights) {
########################################
pscore = as.vector(expit(vc %*% gamma))
n = length(pscore)
### 1. - E[dS/d(alpha.ml,beta.ml)] #####... |
library(methods)
library(RSelenium)
library(testthat)
library(XML)
library(digest)
ISR_login <- Sys.getenv("ISR_login")
ISR_pwd <- Sys.getenv("ISR_pwd")
SAUCE_USERNAME <- Sys.getenv("SAUCE_USERNAME")
SAUCE_ACCESS_KEY <- Sys.getenv("SAUCE_ACCESS_KEY")
machine <- ifelse(Sys.getenv("TRAVIS") == "true", "TRAVIS", "LOCAL"... | /tests/initialize.R | no_license | TheGilt/UITesting | R | false | false | 4,143 | r | library(methods)
library(RSelenium)
library(testthat)
library(XML)
library(digest)
ISR_login <- Sys.getenv("ISR_login")
ISR_pwd <- Sys.getenv("ISR_pwd")
SAUCE_USERNAME <- Sys.getenv("SAUCE_USERNAME")
SAUCE_ACCESS_KEY <- Sys.getenv("SAUCE_ACCESS_KEY")
machine <- ifelse(Sys.getenv("TRAVIS") == "true", "TRAVIS", "LOCAL"... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/appmesh_operations.R
\name{appmesh_delete_route}
\alias{appmesh_delete_route}
\title{Deletes an existing route}
\usage{
appmesh_delete_route(meshName, meshOwner, routeName, virtualRouterName)
}
\arguments{
\item{meshName}{[required] The name ... | /paws/man/appmesh_delete_route.Rd | permissive | sanchezvivi/paws | R | false | true | 1,076 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/appmesh_operations.R
\name{appmesh_delete_route}
\alias{appmesh_delete_route}
\title{Deletes an existing route}
\usage{
appmesh_delete_route(meshName, meshOwner, routeName, virtualRouterName)
}
\arguments{
\item{meshName}{[required] The name ... |
\name{estimatePatternsOneColumn}
\alias{estimatePatternsOneColumn}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Estimate distribution of methylation patterns with one column of counts
}
\description{
This function is part of the inner working of the package.
Please refer to \code{\link{es... | /man/estimatePatternsOneColumn.Rd | no_license | sylvainforet/Bpest | R | false | false | 1,175 | rd | \name{estimatePatternsOneColumn}
\alias{estimatePatternsOneColumn}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{
Estimate distribution of methylation patterns with one column of counts
}
\description{
This function is part of the inner working of the package.
Please refer to \code{\link{es... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utilities.R
\name{summary.tvarGIRF}
\alias{summary.tvarGIRF}
\title{Print a summary of some estimated GIRFs}
\usage{
\method{summary}{tvarGIRF}(object, ...)
}
\arguments{
\item{object}{The result of a call to `GIRF`}
\item{...}{Additional ar... | /man/summary.tvarGIRF.Rd | permissive | angusmoore/tvarGIRF | R | false | true | 397 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utilities.R
\name{summary.tvarGIRF}
\alias{summary.tvarGIRF}
\title{Print a summary of some estimated GIRFs}
\usage{
\method{summary}{tvarGIRF}(object, ...)
}
\arguments{
\item{object}{The result of a call to `GIRF`}
\item{...}{Additional ar... |
data <- read.csv("noOfPages.txt", stringsAsFactors = F, header = FALSE, sep = "|")
incdata = data[, 1]
incdata <- as.numeric(incdata)
brk <- seq(0, 300, 10)
png("q1-histogram1.png")
hist(incdata, main = "Blogs vs. Number of Pages", breaks=brk, freq = T, xlab="Pages", ylab="Blogs")
| /A9/documentation/questions/q1/R/histogram.R | no_license | mkoga001/cs595-f14 | R | false | false | 296 | r | data <- read.csv("noOfPages.txt", stringsAsFactors = F, header = FALSE, sep = "|")
incdata = data[, 1]
incdata <- as.numeric(incdata)
brk <- seq(0, 300, 10)
png("q1-histogram1.png")
hist(incdata, main = "Blogs vs. Number of Pages", breaks=brk, freq = T, xlab="Pages", ylab="Blogs")
|
#
# # The purpose of this script is to create a data object (dto) which will hold all data and metadata.
# # Run the lines below to stitch a basic html output.
knitr::stitch_rmd(
script="./sandbox/map/mmse-map-LH.R",
output="./sandbox/map/stitched-output/mmse-map-LH.md"
)
## The above lines are executed only when... | /sandbox/compile-models-mmse/compile-models-mmse.R | no_license | beccav8/psy564_longitudinal_models | R | false | false | 17,891 | r | #
# # The purpose of this script is to create a data object (dto) which will hold all data and metadata.
# # Run the lines below to stitch a basic html output.
knitr::stitch_rmd(
script="./sandbox/map/mmse-map-LH.R",
output="./sandbox/map/stitched-output/mmse-map-LH.md"
)
## The above lines are executed only when... |
# Course Assignment, Getting and Cleaning Data
# P. Pulley
library(dplyr)
# Download and extract zip files; Load tables. Stitch together "test" and "train" tables.
if(!file.exists("./Assign")){dir.create("./Assign")}
fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Datas... | /run_analysis.R | no_license | pulleyps/Course3_Cleaning_Data_Assignment | R | false | false | 1,975 | r | # Course Assignment, Getting and Cleaning Data
# P. Pulley
library(dplyr)
# Download and extract zip files; Load tables. Stitch together "test" and "train" tables.
if(!file.exists("./Assign")){dir.create("./Assign")}
fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Datas... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mcmcIterator.R
\name{nextStep}
\alias{nextStep}
\title{next step of an MCMC chain}
\usage{
nextStep(object)
}
\arguments{
\item{object}{an mcmc loop object}
}
\description{
just a wrapper for nextElem really.
}
| /man/nextStep.Rd | no_license | bentaylor1/spatsurv | R | false | true | 290 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mcmcIterator.R
\name{nextStep}
\alias{nextStep}
\title{next step of an MCMC chain}
\usage{
nextStep(object)
}
\arguments{
\item{object}{an mcmc loop object}
}
\description{
just a wrapper for nextElem really.
}
|
### Terrence D. Jorgensen
### Last updated: 21 February 2019
##' Parcel-Allocation Variability in Model Ranking
##'
##' This function quantifies and assesses the consequences of parcel-allocation
##' variability for model ranking of structural equation models (SEMs) that
##' differ in their structural specification b... | /semTools/R/PAVranking.R | no_license | lnsongxf/semTools | R | false | false | 61,593 | r | ### Terrence D. Jorgensen
### Last updated: 21 February 2019
##' Parcel-Allocation Variability in Model Ranking
##'
##' This function quantifies and assesses the consequences of parcel-allocation
##' variability for model ranking of structural equation models (SEMs) that
##' differ in their structural specification b... |
# install.packages("arules")
# install.packages("arulesViz", dependencies = TRUE)
# Import libraries
library(arules)
library(arulesViz)
# Import dataset
# dataset = read.csv('../datasets/Grocery.csv', header = FALSE)
# Read transactions
basket = arules::read.transactions('../datasets/Grocery.csv', sep = ',', rm.dupl... | /grocery_analysis.R | no_license | greatsharma/Association-Learning | R | false | false | 1,639 | r | # install.packages("arules")
# install.packages("arulesViz", dependencies = TRUE)
# Import libraries
library(arules)
library(arulesViz)
# Import dataset
# dataset = read.csv('../datasets/Grocery.csv', header = FALSE)
# Read transactions
basket = arules::read.transactions('../datasets/Grocery.csv', sep = ',', rm.dupl... |
library("matrixStats")
rowQuantiles_R <- function(x, probs, na.rm=FALSE, drop=TRUE, ...) {
q <- apply(x, MARGIN=1L, FUN=function(x, probs, na.rm) {
if (!na.rm && any(is.na(x))) {
naValue <- NA_real_
storage.mode(naValue) <- storage.mode(x)
rep(naValue, length(probs))
} else {
as.vect... | /tests/rowQuantiles.R | no_license | kaushikg06/matrixStats | R | false | false | 3,770 | r | library("matrixStats")
rowQuantiles_R <- function(x, probs, na.rm=FALSE, drop=TRUE, ...) {
q <- apply(x, MARGIN=1L, FUN=function(x, probs, na.rm) {
if (!na.rm && any(is.na(x))) {
naValue <- NA_real_
storage.mode(naValue) <- storage.mode(x)
rep(naValue, length(probs))
} else {
as.vect... |
# Introduction
## ══════════════
# • Learning objectives:
## • Learn the R formula interface
## • Specify factor contrasts to test specific hypotheses
## • Perform model comparisons
## • Run and interpret variety of regression models in R
## Set working directory
## ─────────────────────────
## ... | /linear_regression.R | no_license | gsista/Springboard-Capstone-Project | R | false | false | 10,305 | r | # Introduction
## ══════════════
# • Learning objectives:
## • Learn the R formula interface
## • Specify factor contrasts to test specific hypotheses
## • Perform model comparisons
## • Run and interpret variety of regression models in R
## Set working directory
## ─────────────────────────
## ... |
#' A nicer default theme for ggplot2
#'
#' @examples
#' vpc(simple_data$sim, simple_data$obs) + theme_plain()
#'
#' @export
theme_plain <- function () {
ggplot2::theme(
text = ggplot2::element_text(family="sans"),
plot.title = ggplot2::element_text(family="sans", size = 16, vjust = 1.5),
axis.title.x = g... | /R/themes.R | permissive | ronkeizer/vpc | R | false | false | 1,243 | r | #' A nicer default theme for ggplot2
#'
#' @examples
#' vpc(simple_data$sim, simple_data$obs) + theme_plain()
#'
#' @export
theme_plain <- function () {
ggplot2::theme(
text = ggplot2::element_text(family="sans"),
plot.title = ggplot2::element_text(family="sans", size = 16, vjust = 1.5),
axis.title.x = g... |
corr <- function(directory, threshold = 0){
output <- numeric()
names <- dir(directory, pattern = ".csv")
## loop through directory
for (i in 1:length(names)){
file = paste(directory,"/",names[i], sep = "")
temp_table <- read.csv(file, header = TRUE)
temp_complete <- complete.cases(temp_table)
temp_t <- t... | /corr.R | no_license | Sam-Huntington/R-scripts | R | false | false | 546 | r | corr <- function(directory, threshold = 0){
output <- numeric()
names <- dir(directory, pattern = ".csv")
## loop through directory
for (i in 1:length(names)){
file = paste(directory,"/",names[i], sep = "")
temp_table <- read.csv(file, header = TRUE)
temp_complete <- complete.cases(temp_table)
temp_t <- t... |
# Data Check
#
# checks the data is the correct type(s)
# @param data the data passed into the map layer funciton
# @param callingFunc the function calling the data check
dataCheck <- function(data, callingFunc){
if(is.null(data)){
message(paste0("no data supplied to ", callingFunc))
return(FALSE)
}
if(... | /R/google_map_layer_parameters.R | permissive | SymbolixAU/googleway | R | false | false | 7,141 | r | # Data Check
#
# checks the data is the correct type(s)
# @param data the data passed into the map layer funciton
# @param callingFunc the function calling the data check
dataCheck <- function(data, callingFunc){
if(is.null(data)){
message(paste0("no data supplied to ", callingFunc))
return(FALSE)
}
if(... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/conflicts.R
\name{psyperform_conflicts}
\alias{psyperform_conflicts}
\title{This function lists all the conflicts between packages in psyperform
and other packages that you have loaded.}
\usage{
psyperform_conflicts()
}
\description{
There ar... | /man/psyperform_conflicts.Rd | permissive | fmhoeger/psyperform | R | false | true | 587 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/conflicts.R
\name{psyperform_conflicts}
\alias{psyperform_conflicts}
\title{This function lists all the conflicts between packages in psyperform
and other packages that you have loaded.}
\usage{
psyperform_conflicts()
}
\description{
There ar... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/gargle-api-key.R
\name{gargle_api_key}
\alias{gargle_api_key}
\title{API key for demonstration purposes}
\usage{
gargle_api_key()
}
\value{
A Google API key
}
\description{
Returns an API key for use when test driving gargle. Some API request... | /man/gargle_api_key.Rd | permissive | takewiki/gargle | R | false | true | 1,243 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/gargle-api-key.R
\name{gargle_api_key}
\alias{gargle_api_key}
\title{API key for demonstration purposes}
\usage{
gargle_api_key()
}
\value{
A Google API key
}
\description{
Returns an API key for use when test driving gargle. Some API request... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/create_gaussian.R
\name{MFKnockoffs.create.gaussian}
\alias{MFKnockoffs.create.gaussian}
\title{Sample multivariate Gaussian knockoff variables}
\usage{
MFKnockoffs.create.gaussian(X, mu, Sigma, method = c("sdp", "asdp", "equi"),
diag_s = N... | /man/MFKnockoffs.create.gaussian.Rd | no_license | alexrives/MFKnockoffs | R | false | true | 1,293 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/create_gaussian.R
\name{MFKnockoffs.create.gaussian}
\alias{MFKnockoffs.create.gaussian}
\title{Sample multivariate Gaussian knockoff variables}
\usage{
MFKnockoffs.create.gaussian(X, mu, Sigma, method = c("sdp", "asdp", "equi"),
diag_s = N... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/findMarker.R
\name{findMarkerTopTable}
\alias{findMarkerTopTable}
\title{Fetch the table of top markers that pass the filtering}
\usage{
findMarkerTopTable(
inSCE,
log2fcThreshold = 1,
fdrThreshold = 0.05,
minClustExprPerc = 0.7,
ma... | /man/findMarkerTopTable.Rd | permissive | rz2333/singleCellTK | R | false | true | 1,928 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/findMarker.R
\name{findMarkerTopTable}
\alias{findMarkerTopTable}
\title{Fetch the table of top markers that pass the filtering}
\usage{
findMarkerTopTable(
inSCE,
log2fcThreshold = 1,
fdrThreshold = 0.05,
minClustExprPerc = 0.7,
ma... |
load("data/game-data.RData")
source("functions.R", encoding = "UTF-8")
###LOAD TOURNEY/TEAM DATA#####
NCAATourneyDetailedResults<-read.csv("data/MNCAATourneyDetailedResults.csv")
NCAATourneyDetailedResults$Tournament<-1
RegularSeasonDetailedResult<-read.csv("data/MRegularSeasonDetailedResults.csv")
RegularSeasonDeta... | /scrape-data.R | no_license | dlm1223/march-madness | R | false | false | 11,583 | r | load("data/game-data.RData")
source("functions.R", encoding = "UTF-8")
###LOAD TOURNEY/TEAM DATA#####
NCAATourneyDetailedResults<-read.csv("data/MNCAATourneyDetailedResults.csv")
NCAATourneyDetailedResults$Tournament<-1
RegularSeasonDetailedResult<-read.csv("data/MRegularSeasonDetailedResults.csv")
RegularSeasonDeta... |
library(shiny)
library(shinythemes)
library(DT)
library(ggplot2)
library(car)
library(nortest)
library(tseries)
library(RcmdrMisc)
library(lmtest)
datos <-read.csv("www/dataset.csv",dec = ",")
shinyServer(function(input, output) {
output$RawData <- DT::renderDataTable(
DT::datatable({
... | /Learn_new/Shiny_dashboard/Didactic modeling/server.R | no_license | duybluemind1988/R_project | R | false | false | 59,838 | r | library(shiny)
library(shinythemes)
library(DT)
library(ggplot2)
library(car)
library(nortest)
library(tseries)
library(RcmdrMisc)
library(lmtest)
datos <-read.csv("www/dataset.csv",dec = ",")
shinyServer(function(input, output) {
output$RawData <- DT::renderDataTable(
DT::datatable({
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/hvalir.R
\name{hvalir_hvalir}
\alias{hvalir_hvalir}
\title{Hvalir}
\usage{
hvalir_hvalir(con)
}
\arguments{
\item{con}{Tenging við Oracle}
}
\value{
SQL fyrirspurn
}
\description{
Hvalir
}
| /man/hvalir_hvalir.Rd | no_license | vonStadarhraun/mar | R | false | true | 268 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/hvalir.R
\name{hvalir_hvalir}
\alias{hvalir_hvalir}
\title{Hvalir}
\usage{
hvalir_hvalir(con)
}
\arguments{
\item{con}{Tenging við Oracle}
}
\value{
SQL fyrirspurn
}
\description{
Hvalir
}
|
#' @title Confidence intervals for model parameters
#' @description Computes confidence intervals for parameters in a fitted gllvm model.
#'
#' @param object an object of class 'gllvm'.
#' @param level the confidence level. Scalar between 0 and 1.
#' @param parm a specification of which parameters are to be given conf... | /R/confint.gllvm.R | no_license | jebyrnes/gllvm | R | false | false | 3,986 | r | #' @title Confidence intervals for model parameters
#' @description Computes confidence intervals for parameters in a fitted gllvm model.
#'
#' @param object an object of class 'gllvm'.
#' @param level the confidence level. Scalar between 0 and 1.
#' @param parm a specification of which parameters are to be given conf... |
model_FileName <- "DigitRecognizer-Model.RData"
# Libraries
library(shiny)
library(EBImage)
library(nnet)
load(model_FileName)
ui <- fluidPage(
fileInput(inputId = "image",h3("Choose an Image"),multiple=TRUE,accept=c('image/png','image/jpeg')),
textOutput("digit"),
imageOu... | /ProjectUI.R | no_license | sabhi27/Digit_Recognization | R | false | false | 2,267 | r | model_FileName <- "DigitRecognizer-Model.RData"
# Libraries
library(shiny)
library(EBImage)
library(nnet)
load(model_FileName)
ui <- fluidPage(
fileInput(inputId = "image",h3("Choose an Image"),multiple=TRUE,accept=c('image/png','image/jpeg')),
textOutput("digit"),
imageOu... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/io.R
\name{fwrite_mm}
\alias{fwrite_mm}
\title{Efficiently write Matrix Market format}
\usage{
fwrite_mm(x, fname, sep = " ", row.names = TRUE, col.names = TRUE)
}
\arguments{
\item{x}{sparse matrix}
\item{fname}{file name}
\item{sep}{separ... | /man/fwrite_mm.Rd | no_license | tanaylab/tgutil | R | false | true | 513 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/io.R
\name{fwrite_mm}
\alias{fwrite_mm}
\title{Efficiently write Matrix Market format}
\usage{
fwrite_mm(x, fname, sep = " ", row.names = TRUE, col.names = TRUE)
}
\arguments{
\item{x}{sparse matrix}
\item{fname}{file name}
\item{sep}{separ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/preprint_growth.R
\docType{data}
\name{preprint_growth}
\alias{preprint_growth}
\title{Growth in the number of biology preprints posted
Monthly number of biology preprints posted in several widely used archives.}
\format{An object of class \... | /dviz.supp/man/preprint_growth.Rd | permissive | f0nzie/dataviz-wilke-2020 | R | false | true | 1,614 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/preprint_growth.R
\docType{data}
\name{preprint_growth}
\alias{preprint_growth}
\title{Growth in the number of biology preprints posted
Monthly number of biology preprints posted in several widely used archives.}
\format{An object of class \... |
#Load the library
library(dplyr)
library(lubridate)
# Mention the directory path
dir<-"/Users/manavsehgal/Library/Mobile Documents/com~apple~CloudDocs/Work/Study/Coursera/Data-Scientist/datasciencecoursera/ExData_Plotting1"
# Mention the name of the file
file_name<-"household_power_consumption.txt"
#Load the variabl... | /plot4.R | no_license | msehgal13/ExData_Plotting1 | R | false | false | 1,799 | r | #Load the library
library(dplyr)
library(lubridate)
# Mention the directory path
dir<-"/Users/manavsehgal/Library/Mobile Documents/com~apple~CloudDocs/Work/Study/Coursera/Data-Scientist/datasciencecoursera/ExData_Plotting1"
# Mention the name of the file
file_name<-"household_power_consumption.txt"
#Load the variabl... |
detach(Banco)
library(readxl)
Banco <- read_excel("arquivos/Banco.xlsx")
#View(Banco)
attach(Banco)
Banco$data_atual = Sys.Date()
idade = round(difftime(data_atual,datanasc)/365.25)
idade <- as.numeric(idade)
Banco$idade = idade
fax_etaria = cut(Banco$idade, breaks = c(46,50,60,70,80), labels = c(1,2,3,4,5), right... | /calc_risco.R | no_license | flavioti/aula_r | R | false | false | 365 | r | detach(Banco)
library(readxl)
Banco <- read_excel("arquivos/Banco.xlsx")
#View(Banco)
attach(Banco)
Banco$data_atual = Sys.Date()
idade = round(difftime(data_atual,datanasc)/365.25)
idade <- as.numeric(idade)
Banco$idade = idade
fax_etaria = cut(Banco$idade, breaks = c(46,50,60,70,80), labels = c(1,2,3,4,5), right... |
.set_proj_data <- function(proj_data = ""){
l <- try(.Call("PROJ_proj_set_data_dir", proj_data), silent = TRUE)
if (inherits(l, "try-error")) {
ok <- FALSE
} else {
ok <- TRUE
}
ok
}
.onLoad <- function(libname, pkgname) {
pkg_proj_lib <- FALSE
if (tolower(Sys.info()[["sysnam... | /R/zzz.R | no_license | paleolimbot/PROJ | R | false | false | 651 | r | .set_proj_data <- function(proj_data = ""){
l <- try(.Call("PROJ_proj_set_data_dir", proj_data), silent = TRUE)
if (inherits(l, "try-error")) {
ok <- FALSE
} else {
ok <- TRUE
}
ok
}
.onLoad <- function(libname, pkgname) {
pkg_proj_lib <- FALSE
if (tolower(Sys.info()[["sysnam... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plot_psvcsignal.R
\name{plot.psvcsignal}
\alias{plot.psvcsignal}
\title{Plotting function for \code{psVCSignal}}
\usage{
\method{plot}{psvcsignal}(x, ..., xlab = " ", ylab = " ", Resol = 100)
}
\arguments{
\item{x}{the P-spline objec... | /man/plot.psvcsignal.Rd | no_license | cran/JOPS | R | false | true | 2,211 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plot_psvcsignal.R
\name{plot.psvcsignal}
\alias{plot.psvcsignal}
\title{Plotting function for \code{psVCSignal}}
\usage{
\method{plot}{psvcsignal}(x, ..., xlab = " ", ylab = " ", Resol = 100)
}
\arguments{
\item{x}{the P-spline objec... |
#' @param as.df [\code{character(1)}]\cr
#' Return one data.frame as result - or a list of lists of objects?.
#' Default is \code{FALSE}
| /man-roxygen/arg_bmr_asdf.R | no_license | dickoa/mlr | R | false | false | 142 | r | #' @param as.df [\code{character(1)}]\cr
#' Return one data.frame as result - or a list of lists of objects?.
#' Default is \code{FALSE}
|
#' Measurement units in a dataframe
#'
#' Returns a dataframe with measurement units from a parsed OpenClinica
#' odm1.3 .xml export file.
#'
#' @param parsed_xml An object of class \code{XMLInternalDocument}, as returned
#' by \code{XML::xmlParse()}.
#'
#' @return A dataframe.
#' @export
#'
#' @examples
#' # The examp... | /R/ox_units.R | no_license | ccollins0601/ox | R | false | false | 1,682 | r | #' Measurement units in a dataframe
#'
#' Returns a dataframe with measurement units from a parsed OpenClinica
#' odm1.3 .xml export file.
#'
#' @param parsed_xml An object of class \code{XMLInternalDocument}, as returned
#' by \code{XML::xmlParse()}.
#'
#' @return A dataframe.
#' @export
#'
#' @examples
#' # The examp... |
# The data household_power_comsumption has been stored in the working directiory
#read the data into the working environment
data1 <- read.csv("household_power_consumption.txt", header =T, sep=";", na.strings ="?")
## use subset to select 2 days data for plotting
ndata <- subset(data1, data1$Date == '1/2/2007'|data1... | /plot2.R | no_license | vivianni/ExploratoryDataAnalysis | R | false | false | 866 | r |
# The data household_power_comsumption has been stored in the working directiory
#read the data into the working environment
data1 <- read.csv("household_power_consumption.txt", header =T, sep=";", na.strings ="?")
## use subset to select 2 days data for plotting
ndata <- subset(data1, data1$Date == '1/2/2007'|data1... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Musicnotation.R
\name{Musicnotation}
\alias{Musicnotation}
\title{Function Musicnotation}
\usage{
Musicnotation(data_sheet, ...)
}
\arguments{
\item{data_sheet}{\bold{either} a data.frame f.e imported from a data sheet containing\cr
"Name","i... | /man/Musicnotation.Rd | no_license | cran/Dominance | R | false | true | 3,604 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Musicnotation.R
\name{Musicnotation}
\alias{Musicnotation}
\title{Function Musicnotation}
\usage{
Musicnotation(data_sheet, ...)
}
\arguments{
\item{data_sheet}{\bold{either} a data.frame f.e imported from a data sheet containing\cr
"Name","i... |
#' select or remove tokens from a tokens object
#'
#' This function selects or discards tokens from a \link{tokens} objects, with
#' the shortcut \code{tokens_remove(x, features)} defined as a shortcut for
#' \code{tokens_select(x, features, selection = "remove")}. The most common
#' usage for \code{tokens_remove} ... | /R/tokens_select.R | no_license | patperry/quanteda | R | false | false | 8,062 | r | #' select or remove tokens from a tokens object
#'
#' This function selects or discards tokens from a \link{tokens} objects, with
#' the shortcut \code{tokens_remove(x, features)} defined as a shortcut for
#' \code{tokens_select(x, features, selection = "remove")}. The most common
#' usage for \code{tokens_remove} ... |
# Hierarchical Linear Model - Determine Individual Level Effect - Estimate the values in the model for each respondent
# Roller Coaster Conjoint Analysis: levels of maximum speed, height, construction type , and theme.
# when you have multiple observations for an individual or other grouping factor of interest, you sho... | /GGplot2.R | no_license | Crystal0108W/R | R | false | false | 6,043 | r | # Hierarchical Linear Model - Determine Individual Level Effect - Estimate the values in the model for each respondent
# Roller Coaster Conjoint Analysis: levels of maximum speed, height, construction type , and theme.
# when you have multiple observations for an individual or other grouping factor of interest, you sho... |
library(ape)
testtree <- read.tree("3346_1.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="3346_1_unrooted.txt") | /codeml_files/newick_trees_processed/3346_1/rinput.R | no_license | DaniBoo/cyanobacteria_project | R | false | false | 135 | r | library(ape)
testtree <- read.tree("3346_1.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="3346_1_unrooted.txt") |
#' module_aglu_LA103.ag_R_C_Y_GLU
#'
#' Calculate production, harvested area, and yield by region, crop, GLU, and year.
#'
#' @param command API command to execute
#' @param ... other optional parameters, depending on command
#' @return Depends on \code{command}: either a vector of required inputs,
#' a vector of outpu... | /R/zchunk_LA103.ag_R_C_Y_GLU.R | permissive | qingyihou/gcamdata | R | false | false | 8,387 | r | #' module_aglu_LA103.ag_R_C_Y_GLU
#'
#' Calculate production, harvested area, and yield by region, crop, GLU, and year.
#'
#' @param command API command to execute
#' @param ... other optional parameters, depending on command
#' @return Depends on \code{command}: either a vector of required inputs,
#' a vector of outpu... |
ggum <- function(x, K=NULL, method="LA", Iters=100, Smpl=1000,
Thin=1, a.s=0.234, temp=1e-2, tmax=NULL,
algo="GA", seed=666, Interval=1e-8){
### Start====
set.seed(seed)
#require(LaplacesDemon)
#require(compiler)
#require(parallel)
#require(tidyr)
CPUs = detectCores(all.... | /R/ggum.R | no_license | vthorrf/birm | R | false | false | 7,726 | r | ggum <- function(x, K=NULL, method="LA", Iters=100, Smpl=1000,
Thin=1, a.s=0.234, temp=1e-2, tmax=NULL,
algo="GA", seed=666, Interval=1e-8){
### Start====
set.seed(seed)
#require(LaplacesDemon)
#require(compiler)
#require(parallel)
#require(tidyr)
CPUs = detectCores(all.... |
# description -------------------------------------------------------------
# scraps links to laws
# scraps info on developments pertaining to each law => basis for 2018_law_analysis
# scraps from each law development links to votes
# scraps pdfs behind each link on votes => basis for tesseract_extract_individual_vote... | /BiHLaws/script/2018_exctract_laws_and_votes.R | no_license | rs2903/BiH | R | false | false | 4,100 | r | # description -------------------------------------------------------------
# scraps links to laws
# scraps info on developments pertaining to each law => basis for 2018_law_analysis
# scraps from each law development links to votes
# scraps pdfs behind each link on votes => basis for tesseract_extract_individual_vote... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/testData.R
\docType{data}
\name{testCounts}
\alias{testCounts}
\title{Counts data used to demonstrate sp.scRNAseq package.}
\format{matrix
\describe{
\item{rownames}{Gene names}
\item{colnames}{Samples. Singlets prefixed with "s" and ... | /man/testCounts.Rd | no_license | EngeLab/kNNclassification | R | false | true | 454 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/testData.R
\docType{data}
\name{testCounts}
\alias{testCounts}
\title{Counts data used to demonstrate sp.scRNAseq package.}
\format{matrix
\describe{
\item{rownames}{Gene names}
\item{colnames}{Samples. Singlets prefixed with "s" and ... |
library(ggplot2)
require(devEMF)
emf('180ms.emf')
#png("180ms.emf")
#postscript("plot.eps")
#emf("plot.emf")
# header = TRUE ignores the first line, check.names = FALSE allows '+' in 'C++'
benchmark <- read.table("180ms.dat", header = TRUE, row.names = "vwnd", check.names = FALSE)
# 't()' is matrix tranposition, 'b... | /R/180ms.R | no_license | david78k/migration | R | false | false | 751 | r | library(ggplot2)
require(devEMF)
emf('180ms.emf')
#png("180ms.emf")
#postscript("plot.eps")
#emf("plot.emf")
# header = TRUE ignores the first line, check.names = FALSE allows '+' in 'C++'
benchmark <- read.table("180ms.dat", header = TRUE, row.names = "vwnd", check.names = FALSE)
# 't()' is matrix tranposition, 'b... |
# tests retrieval of objective function
# getObjective
test.getObjective <- function()
{
unitTestPath <- get("TestPath", envir = .RNMImportTestEnv)
setNmPath("internalunit", file.path(unitTestPath, "testdata/TestRun") )
run1 <- importNm( "TestData1.ctl", path = file.path(unitTestPath, "testdata/TestRun"... | /tests/unittests/runit.retrievemisc.R | no_license | MikeKSmith/RNMImport | R | false | false | 10,154 | r |
# tests retrieval of objective function
# getObjective
test.getObjective <- function()
{
unitTestPath <- get("TestPath", envir = .RNMImportTestEnv)
setNmPath("internalunit", file.path(unitTestPath, "testdata/TestRun") )
run1 <- importNm( "TestData1.ctl", path = file.path(unitTestPath, "testdata/TestRun"... |
# Exemplo de conversao de tabela de dados em
# uma tabela de contingencia
# Uma tabela de dados costuma ser apresentada
# com um paciente por linha, e os dados em colunas
library("epiR")
filename <- "MPT0164_GESTANTES_AFolico_B12_rubeola.txt"
gestantes <- read.table(filename,header=TRUE,sep="\t",dec=".")
# adiciona... | /Aula02/R/dataframe_to_table.R | no_license | yadevi/2020 | R | false | false | 825 | r | # Exemplo de conversao de tabela de dados em
# uma tabela de contingencia
# Uma tabela de dados costuma ser apresentada
# com um paciente por linha, e os dados em colunas
library("epiR")
filename <- "MPT0164_GESTANTES_AFolico_B12_rubeola.txt"
gestantes <- read.table(filename,header=TRUE,sep="\t",dec=".")
# adiciona... |
numSamples <- 1000
obsPerSample <- 1000
###Uniform Distr
resultsUniform <- unlist(lapply(1:numSamples, function(x){
return(mean(
runif(obsPerSample, min = 0, max = 100)
)
)
}))
resultsExponential <- unlist(lapply(1:numSamples, function(x){
return(mean(
... | /Notes/2017-02-06 Statistical Foundations for DS and ML, Metis/CentralLimitTheorem.R | no_license | danaoira/misc | R | false | false | 583 | r | numSamples <- 1000
obsPerSample <- 1000
###Uniform Distr
resultsUniform <- unlist(lapply(1:numSamples, function(x){
return(mean(
runif(obsPerSample, min = 0, max = 100)
)
)
}))
resultsExponential <- unlist(lapply(1:numSamples, function(x){
return(mean(
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.