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 |
|---|---|---|---|---|---|---|---|---|---|
## MannWhitney_SplitYearSensitivity.R
# This script will test the sensitivity of the Mann-Whitney results to the year chosen for the split.
source(file.path("code", "paths+packages.R"))
## load data
gage_regions <-
readr::read_csv(file.path("results", "00_SelectGagesForAnalysis_GageRegions.csv"))
gage_sample_annu... | /figures_manuscript/MannWhitney_SplitYearSensitivity.R | no_license | dry-rivers-rcn/IntermittencyTrends | R | false | false | 7,667 | r | ## MannWhitney_SplitYearSensitivity.R
# This script will test the sensitivity of the Mann-Whitney results to the year chosen for the split.
source(file.path("code", "paths+packages.R"))
## load data
gage_regions <-
readr::read_csv(file.path("results", "00_SelectGagesForAnalysis_GageRegions.csv"))
gage_sample_annu... |
\name{CPTtools-package}
\alias{CPTtools-package}
\alias{CPTtools}
\docType{package}
\title{
\packageTitle{CPTtools}
}
\description{
\packageDescription{CPTtools}
}
\details{
The DESCRIPTION file:
\packageDESCRIPTION{CPTtools}
CPTtools is a collection of various bits of R code useful for processing
Bayes net output. ... | /man/CPTtools-package.Rd | permissive | erge324/CPTtools | R | false | false | 16,265 | rd | \name{CPTtools-package}
\alias{CPTtools-package}
\alias{CPTtools}
\docType{package}
\title{
\packageTitle{CPTtools}
}
\description{
\packageDescription{CPTtools}
}
\details{
The DESCRIPTION file:
\packageDESCRIPTION{CPTtools}
CPTtools is a collection of various bits of R code useful for processing
Bayes net output. ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/datasets.R
\name{data_path}
\alias{data_path}
\title{Represents a path to data in a datastore.}
\usage{
data_path(datastore, path_on_datastore = NULL, name = NULL)
}
\arguments{
\item{datastore}{The Datastore to reference.}
\item{path_on_dat... | /man/data_path.Rd | permissive | revodavid/azureml-sdk-for-r | R | false | true | 1,314 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/datasets.R
\name{data_path}
\alias{data_path}
\title{Represents a path to data in a datastore.}
\usage{
data_path(datastore, path_on_datastore = NULL, name = NULL)
}
\arguments{
\item{datastore}{The Datastore to reference.}
\item{path_on_dat... |
# nocov - compat-purrr (last updated: rlang 0.0.0.9007)
# This file serves as a reference for compatibility functions for
# purrr. They are not drop-in replacements but allow a similar style
# of programming. This is useful in cases where purrr is too heavy a
# package to depend on. Please find the most recent version... | /R/compat-purrr.R | no_license | krlmlr/brushthat | R | false | false | 3,736 | r | # nocov - compat-purrr (last updated: rlang 0.0.0.9007)
# This file serves as a reference for compatibility functions for
# purrr. They are not drop-in replacements but allow a similar style
# of programming. This is useful in cases where purrr is too heavy a
# package to depend on. Please find the most recent version... |
gammaresiduals <-
function(Y,X,model){
Y <- as.matrix(Y)
residuals <- model$residuals
variance <- model$variance
phi <- model$precision
yestimado <- model$fitted.values
#Absolute residuals
rabs<-abs(residuals)
#Standardized Weighted Residual 1
rp<-residuals/sqrt(variance)
#... | /R/gammaresiduals.R | no_license | cran/Bayesiangammareg | R | false | false | 688 | r | gammaresiduals <-
function(Y,X,model){
Y <- as.matrix(Y)
residuals <- model$residuals
variance <- model$variance
phi <- model$precision
yestimado <- model$fitted.values
#Absolute residuals
rabs<-abs(residuals)
#Standardized Weighted Residual 1
rp<-residuals/sqrt(variance)
#... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Package.R
\docType{package}
\name{PLEFinal-package}
\alias{PLEFinal}
\alias{PLEFinal-package}
\title{PLEFinal: A Package Skeleton for Comparative Effectiveness Studies}
\description{
A skeleton package, to be used as a starting point ... | /PLEFinal/man/SkeletonComparativeEffectStudy-package.Rd | permissive | jennifercelane/PLEMSKAI_working | R | false | true | 390 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Package.R
\docType{package}
\name{PLEFinal-package}
\alias{PLEFinal}
\alias{PLEFinal-package}
\title{PLEFinal: A Package Skeleton for Comparative Effectiveness Studies}
\description{
A skeleton package, to be used as a starting point ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/get.IDR.discrete.R
\name{get.IDR.discrete}
\alias{get.IDR.discrete}
\title{compute IDR for discrete categories}
\usage{
get.IDR.discrete(idr, cat.counts)
}
\arguments{
\item{idr}{local idr for each category.}
\item{cat.counts}{the... | /man/get.IDR.discrete.Rd | no_license | TaoYang-dev/gIDR | R | false | true | 592 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/get.IDR.discrete.R
\name{get.IDR.discrete}
\alias{get.IDR.discrete}
\title{compute IDR for discrete categories}
\usage{
get.IDR.discrete(idr, cat.counts)
}
\arguments{
\item{idr}{local idr for each category.}
\item{cat.counts}{the... |
## Packages used
library(dplyr); library(tidyr)
## Download data
if(!file.exists("./data")){
dir.create("./data")
fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip"
download.file(fileUrl, destfile = "./data/zip.zip", method = "curl")
rm(f... | /run_analysis.R | no_license | mattayes/samsung-har | R | false | false | 3,177 | r | ## Packages used
library(dplyr); library(tidyr)
## Download data
if(!file.exists("./data")){
dir.create("./data")
fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip"
download.file(fileUrl, destfile = "./data/zip.zip", method = "curl")
rm(f... |
library(tidyverse)
library(scales)
library(Cairo)
theme_set(theme_classic())
Ex_1 <- tribble(
~Tier, ~Number_Account, ~Percentage_Accounts, ~Revenue_M, ~Percentage_Revenue,
'A', 77, 7.08, 4.68, 25,
'A+', 19, 1.75, 3.93, 21,
'B', 338, 31.07, 5.98, 32,
'C', 425, 39.06, 2.81, 15,
'D', 24, 2.21, 0.37, 2
) %>%... | /Storytelling_with_Data/2019_10_SWD_Challenge.R | no_license | jorgel-mendes/Behold-the-Vision | R | false | false | 2,875 | r | library(tidyverse)
library(scales)
library(Cairo)
theme_set(theme_classic())
Ex_1 <- tribble(
~Tier, ~Number_Account, ~Percentage_Accounts, ~Revenue_M, ~Percentage_Revenue,
'A', 77, 7.08, 4.68, 25,
'A+', 19, 1.75, 3.93, 21,
'B', 338, 31.07, 5.98, 32,
'C', 425, 39.06, 2.81, 15,
'D', 24, 2.21, 0.37, 2
) %>%... |
# scalar(스칼라): 한개의 값이 저장된 객체(object, 변수 variable).
# vector(벡터): 한가지 타입(유형)의 여러개의 값이 1차원으로 저장된 객체.
# scalar의 예
x <- 100 # x: 숫자 한개를 저장하고 있는 scalar
name <- '오쌤' # name: 문자열 한개를 저장하고 있는 scalar
name
# R에서는 문자열을 작은따옴표('') 또는 큰따옴표("")로 묶을 수 있음.
# (비교) SQL에서는 문자열을 사용할 때 작은따옴표만 사용해야 함.
is_big <- TRUE # 논릿값(logi... | /r02_scalar_vector.R | no_license | seanhong7777/R | R | false | false | 3,065 | r | # scalar(스칼라): 한개의 값이 저장된 객체(object, 변수 variable).
# vector(벡터): 한가지 타입(유형)의 여러개의 값이 1차원으로 저장된 객체.
# scalar의 예
x <- 100 # x: 숫자 한개를 저장하고 있는 scalar
name <- '오쌤' # name: 문자열 한개를 저장하고 있는 scalar
name
# R에서는 문자열을 작은따옴표('') 또는 큰따옴표("")로 묶을 수 있음.
# (비교) SQL에서는 문자열을 사용할 때 작은따옴표만 사용해야 함.
is_big <- TRUE # 논릿값(logi... |
#html_session_try adds:
#1.auto retry functionality using exponantial delay(2s,4s,8s,16s etc)
#2.use tryCatch to create robust scraper, any network issues or error will not break the script. It's safe to run it in loops
#3.keep track of unsuccessful request(including both error and warning).Conditions of failed request... | /R Projects/function/html_session_try.R | no_license | yusuzech/web-scraping-projects | R | false | false | 1,613 | r | #html_session_try adds:
#1.auto retry functionality using exponantial delay(2s,4s,8s,16s etc)
#2.use tryCatch to create robust scraper, any network issues or error will not break the script. It's safe to run it in loops
#3.keep track of unsuccessful request(including both error and warning).Conditions of failed request... |
# cmd_args=commandArgs(TRUE)
#
# ngenecl <- as.numeric(cmd_args[1]) # cells per cell type
# out <- cmd_args[2]
source("/proj/milovelab/mu/SC-ASE/simulation/cluster.R")
source("/proj/milovelab/mu/SC-ASE/simulation/fusedlasso.R")
library("smurf")
library(emdbook)
library(mclust)
library(pbapply)
library(aricode)
librar... | /simulation/sim2.R | no_license | Wancen/SC-ASE | R | false | false | 3,866 | r | # cmd_args=commandArgs(TRUE)
#
# ngenecl <- as.numeric(cmd_args[1]) # cells per cell type
# out <- cmd_args[2]
source("/proj/milovelab/mu/SC-ASE/simulation/cluster.R")
source("/proj/milovelab/mu/SC-ASE/simulation/fusedlasso.R")
library("smurf")
library(emdbook)
library(mclust)
library(pbapply)
library(aricode)
librar... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/currentarrows.R
\name{currentarrows}
\alias{currentarrows}
\title{Plot arrows and segments showing the size and direction of currents.}
\usage{
currentarrows(
data,
maxsize = 0.5,
maxn,
col = "blue",
lwd = 2,
arrowsize = 0.2,
ce... | /man/currentarrows.Rd | no_license | Hafro/geo | R | false | true | 986 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/currentarrows.R
\name{currentarrows}
\alias{currentarrows}
\title{Plot arrows and segments showing the size and direction of currents.}
\usage{
currentarrows(
data,
maxsize = 0.5,
maxn,
col = "blue",
lwd = 2,
arrowsize = 0.2,
ce... |
## This function creates a special "matrix" object that can cache its inverse
makeCacheMatrix <- function(x = matrix()) {
}
## This function computes the inverse of the special "matrix" returned by makeCacheMatrix above. If the inverse has already been calculated (and the matrix has not changed), then the cacheso... | /cachematrix.R | no_license | datatool/ProgrammingAssignment2 | R | false | false | 619 | r | ## This function creates a special "matrix" object that can cache its inverse
makeCacheMatrix <- function(x = matrix()) {
}
## This function computes the inverse of the special "matrix" returned by makeCacheMatrix above. If the inverse has already been calculated (and the matrix has not changed), then the cacheso... |
#!/usr/bin/Rscript
# Daily Pick
##############
#
# Standalone script intended to be run by Cron job to report daily picks.
#
delta=30
theDate=as.Date(Sys.time())
#Share Select
setwd("/home/raffles/Raffles/")
source("Quantlib.R")
setwd("./Data/")
loadLocalData()
#Loads basic libraries and sets up required environme... | /DailyPick.R.save | no_license | piratesjustarr/Raffles | R | false | false | 1,755 | save | #!/usr/bin/Rscript
# Daily Pick
##############
#
# Standalone script intended to be run by Cron job to report daily picks.
#
delta=30
theDate=as.Date(Sys.time())
#Share Select
setwd("/home/raffles/Raffles/")
source("Quantlib.R")
setwd("./Data/")
loadLocalData()
#Loads basic libraries and sets up required environme... |
testlist <- list(scale = 1.17613105186789e-309, shape = -2.95612684604669e-196)
result <- do.call(bama:::rand_igamma,testlist)
str(result) | /bama/inst/testfiles/rand_igamma/AFL_rand_igamma/rand_igamma_valgrind_files/1615926417-test.R | no_license | akhikolla/updatedatatype-list1 | R | false | false | 138 | r | testlist <- list(scale = 1.17613105186789e-309, shape = -2.95612684604669e-196)
result <- do.call(bama:::rand_igamma,testlist)
str(result) |
#代码更适合批量化和自动化,鼠标是替代不了的 | /excel案例.R | no_license | liuiscoding/R_learn | R | false | false | 64 | r | #代码更适合批量化和自动化,鼠标是替代不了的 |
gap.barplot<-function (y,gap,xaxlab,xtics,yaxlab,ytics,xlim=NA,ylim=NA,
xlab=NULL,ylab=NULL,horiz=FALSE,col=NULL,...) {
if (missing(y)) stop("y values required")
if(missing(xtics)) xtics <- 1:length(y)
if (missing(gap)) stop("gap must be specified")
if (is.null(ylab)) ylab <- deparse(substitute(y))
if (is.n... | /primeiroProjetoR/plotrix/R/gap.barplot.R | no_license | bernardomsvieira/Rproject | R | false | false | 2,321 | r | gap.barplot<-function (y,gap,xaxlab,xtics,yaxlab,ytics,xlim=NA,ylim=NA,
xlab=NULL,ylab=NULL,horiz=FALSE,col=NULL,...) {
if (missing(y)) stop("y values required")
if(missing(xtics)) xtics <- 1:length(y)
if (missing(gap)) stop("gap must be specified")
if (is.null(ylab)) ylab <- deparse(substitute(y))
if (is.n... |
library(multistate)
### Name: sm4rs
### Title: 4-State Relative Survival Semi-Markov Model with Additive Risks
### Aliases: sm4rs
### Keywords: semi-Markov relative survival
### ** Examples
# import the observed data
# (X=1 corresponds to initial state with a functioning graft, X=2 to acute rejection episode,
# X=... | /data/genthat_extracted_code/multistate/examples/sm4rs.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 1,506 | r | library(multistate)
### Name: sm4rs
### Title: 4-State Relative Survival Semi-Markov Model with Additive Risks
### Aliases: sm4rs
### Keywords: semi-Markov relative survival
### ** Examples
# import the observed data
# (X=1 corresponds to initial state with a functioning graft, X=2 to acute rejection episode,
# X=... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/sw.R
\name{T68fromT90}
\alias{T68fromT90}
\title{Convert from ITS-90 to IPTS-68 temperature}
\usage{
T68fromT90(temperature)
}
\arguments{
\item{temperature}{Vector of temperatures expressed in the ITS-90 scale.}
}
\value{
Temperature express... | /pkgs/oce/man/T68fromT90.Rd | no_license | vaguiar/EDAV_Project_2017 | R | false | true | 2,283 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/sw.R
\name{T68fromT90}
\alias{T68fromT90}
\title{Convert from ITS-90 to IPTS-68 temperature}
\usage{
T68fromT90(temperature)
}
\arguments{
\item{temperature}{Vector of temperatures expressed in the ITS-90 scale.}
}
\value{
Temperature express... |
setwd(normalizePath(dirname(R.utils::commandArgs(asValues=TRUE)$"f")))
source('../h2o-runit.R')
test.pub_697_exec_bad_key_name <- function() {
prostatePath = locate("smalldata/prostate/prostate.csv")
prostate.hex = h2o.importFile(path = prostatePath, destination_frame = "prostate.hex")
prostate.local = as.data.frame... | /h2o-r/tests/testdir_jira/runit_pub_697_exec_bad_key_name.R | permissive | tamseo/h2o-3 | R | false | false | 711 | r | setwd(normalizePath(dirname(R.utils::commandArgs(asValues=TRUE)$"f")))
source('../h2o-runit.R')
test.pub_697_exec_bad_key_name <- function() {
prostatePath = locate("smalldata/prostate/prostate.csv")
prostate.hex = h2o.importFile(path = prostatePath, destination_frame = "prostate.hex")
prostate.local = as.data.frame... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ParetoShrinkage.R
\name{R2_Wherry}
\alias{R2_Wherry}
\title{R2_Wherry function}
\usage{
R2_Wherry(N, p, R2)
}
\arguments{
\item{N}{Sample size}
\item{p}{number of predictors}
\item{R2}{R-squared}
}
\value{
R2_W formula-adjus... | /man/R2_Wherry.Rd | no_license | Diversity-ParetoOptimal/ParetoR | R | false | true | 613 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ParetoShrinkage.R
\name{R2_Wherry}
\alias{R2_Wherry}
\title{R2_Wherry function}
\usage{
R2_Wherry(N, p, R2)
}
\arguments{
\item{N}{Sample size}
\item{p}{number of predictors}
\item{R2}{R-squared}
}
\value{
R2_W formula-adjus... |
###############################################################################
# #
# execute exp3_bayes_t_priors.R #
# #
###############################################################################
setwd("Documents/wiskunde/2017-2018/bachelor_project/R/... | /R/exp3_bayes_tpriors.R | no_license | StudentThom/handin_bachelor_project | R | false | false | 3,190 | r | ###############################################################################
# #
# execute exp3_bayes_t_priors.R #
# #
###############################################################################
setwd("Documents/wiskunde/2017-2018/bachelor_project/R/... |
#######################
### Meta-Analyse: Korrelationen
# von Julien P. Irmer
## Vorbereitung
library(metafor)
## Übersicht über den Datensatz verschaffen
head(dat.molloy2014)
summary(dat.molloy2014$ri)
## Grafische Veranschaulichung der Beziehung zwischen der Medikamenteneinnahme und der Gewissenhaftigkeit
boxplot... | /content/post/KliPPs_MSc5a_R_Files/8_meta-analyse_korrelationen_RCode.R | no_license | martscht/projekte | R | false | false | 2,090 | r | #######################
### Meta-Analyse: Korrelationen
# von Julien P. Irmer
## Vorbereitung
library(metafor)
## Übersicht über den Datensatz verschaffen
head(dat.molloy2014)
summary(dat.molloy2014$ri)
## Grafische Veranschaulichung der Beziehung zwischen der Medikamenteneinnahme und der Gewissenhaftigkeit
boxplot... |
#######################################################################################
#
# This file is Question5.R
# The purpose is to address the fifth question on the merged data.
# "Cut the GDP rankings into 5 separate quantile groups."
# "Make a table versus Income Group."
# "How man... | /Analysis/Question5.R | no_license | bgobran/CaseStudy1FinalVersion | R | false | false | 3,259 | r | #######################################################################################
#
# This file is Question5.R
# The purpose is to address the fifth question on the merged data.
# "Cut the GDP rankings into 5 separate quantile groups."
# "Make a table versus Income Group."
# "How man... |
#' Print DataM Object
#'
#' Modifies the "print" function to take objects of class \code{DataM} (or any of its subclasses) and print out a matrix where the first column is the dependent variable and the remaining columns are the independent variables.
#'
#' @param DataM An object of class DataM
#'
#' @author Thomas... | /MyPackage/R/print-mod.R | no_license | thomasscarroll89/RPackageProblemSet | R | false | false | 573 | r | #' Print DataM Object
#'
#' Modifies the "print" function to take objects of class \code{DataM} (or any of its subclasses) and print out a matrix where the first column is the dependent variable and the remaining columns are the independent variables.
#'
#' @param DataM An object of class DataM
#'
#' @author Thomas... |
testlist <- list(data = structure(c(6.53867576132537e+286, 6.53867576126997e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53... | /biwavelet/inst/testfiles/rcpp_row_quantile/libFuzzer_rcpp_row_quantile/rcpp_row_quantile_valgrind_files/1610554326-test.R | no_license | akhikolla/updated-only-Issues | R | false | false | 713 | r | testlist <- list(data = structure(c(6.53867576132537e+286, 6.53867576126997e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53867576132537e+286, 6.53... |
#Read the two files
NEI <- readRDS("summarySCC_PM25.rds")
SCC <- readRDS("Source_Classification_Code.rds")
str(NEI)
library(ggplot2)
library(plyr)
#Retain just the Baltimore City data
NEI_Baltimore <- NEI[NEI$fips == "24510",]
#Convert type variable to a factor
NEI_Baltimore$type <- as.factor(NEI_Baltimore$type)
#Ag... | /Exploratory_Data_Analysis_Assignment2/plot3.R | no_license | sharathlives/JohnHopkins_Coursera_Exploratory_Data_Analysis | R | false | false | 905 | r | #Read the two files
NEI <- readRDS("summarySCC_PM25.rds")
SCC <- readRDS("Source_Classification_Code.rds")
str(NEI)
library(ggplot2)
library(plyr)
#Retain just the Baltimore City data
NEI_Baltimore <- NEI[NEI$fips == "24510",]
#Convert type variable to a factor
NEI_Baltimore$type <- as.factor(NEI_Baltimore$type)
#Ag... |
library(lattice)
extract_chrom <- function(t, thisdata, productmz, extraction_window=0.05)
{
this_spectrum = subset(thisdata, SEC == t)
return(sum(subset(this_spectrum, MZ > productmz-(extraction_window/2) & MZ < productmz+(extraction_window/2))$INT))
}
graphme <- function(xxp,allmx){
xxp <- xxp[length(xxp):1]
... | /analysis/scripts/plotChrom.R | permissive | msproteomicstools/msproteomicstools | R | false | false | 2,920 | r | library(lattice)
extract_chrom <- function(t, thisdata, productmz, extraction_window=0.05)
{
this_spectrum = subset(thisdata, SEC == t)
return(sum(subset(this_spectrum, MZ > productmz-(extraction_window/2) & MZ < productmz+(extraction_window/2))$INT))
}
graphme <- function(xxp,allmx){
xxp <- xxp[length(xxp):1]
... |
kurtosis <-
function(x) {
x<-na.omit(x)
n<-length(x)
suma<-sum((x-mean(x))^4)/(var(x))^2
k <- n*(n+1)*suma/((n-1)*(n-2)*(n-3)) - 3*(n-1)^2/((n-2)*(n-3))
return(k)
}
| /R/kurtosis.R | no_license | cran/agricolae | R | false | false | 173 | r | kurtosis <-
function(x) {
x<-na.omit(x)
n<-length(x)
suma<-sum((x-mean(x))^4)/(var(x))^2
k <- n*(n+1)*suma/((n-1)*(n-2)*(n-3)) - 3*(n-1)^2/((n-2)*(n-3))
return(k)
}
|
library(shiny)
library(gapminder)
library(dplyr)
library(plotly)
library(ggplot2)
library()
server <- function(input, output){
rGDP <- reactive({ input$GDP })
rContinent <- reactive({ input$Continent})
output$scatterPlot <- renderPlot({
ggplot(subset(gapminder, continent == rContinent() & ... | /server.R | no_license | brianmblakely/DataProduct | R | false | false | 1,149 | r | library(shiny)
library(gapminder)
library(dplyr)
library(plotly)
library(ggplot2)
library()
server <- function(input, output){
rGDP <- reactive({ input$GDP })
rContinent <- reactive({ input$Continent})
output$scatterPlot <- renderPlot({
ggplot(subset(gapminder, continent == rContinent() & ... |
#include <AudioUnit/AudioUnit.r>
#include "FullBacanoVersion.h"
// Note that resource IDs must be spaced 2 apart for the 'STR ' name and description
#define kAudioUnitResID_FullBacano 1000
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ FullBacano~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#define RES_ID kAudioUnitRe... | /FullBacano/FullBacano/FullBacano.r | no_license | activata/FullBacano | R | false | false | 641 | r | #include <AudioUnit/AudioUnit.r>
#include "FullBacanoVersion.h"
// Note that resource IDs must be spaced 2 apart for the 'STR ' name and description
#define kAudioUnitResID_FullBacano 1000
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ FullBacano~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#define RES_ID kAudioUnitRe... |
#' Model Playground (Gadget) UI Function
#'
#' @param id, character used to specify namespace, see \code{shiny::\link[shiny]{NS}}
#'
#' @importFrom shiny tagList
#'
#' @return a \code{shiny::\link[shiny]{tag}} containing UI elements
#'
#' @export
patientGraphUI <- function(id) {
ns <- shiny::NS(id)
bs4Dash::bs4C... | /R/gadget.R | no_license | ddezel/CardioResp | R | false | false | 1,544 | r | #' Model Playground (Gadget) UI Function
#'
#' @param id, character used to specify namespace, see \code{shiny::\link[shiny]{NS}}
#'
#' @importFrom shiny tagList
#'
#' @return a \code{shiny::\link[shiny]{tag}} containing UI elements
#'
#' @export
patientGraphUI <- function(id) {
ns <- shiny::NS(id)
bs4Dash::bs4C... |
##First all data is read and then a subset is taken.
Dataset<-read.table("household_power_consumption.txt", header = TRUE, sep=";", na.strings = "?")
Dataset<-subset(Dataset, Date=="2/2/2007"|Date=="1/2/2007")
#Extra column created psting date and time together
Dataset$DateTime <-paste(Dataset$Date, Dataset$Time)
pn... | /plot2.R | no_license | FlorienM/ExData_Plotting1 | R | false | false | 556 | r | ##First all data is read and then a subset is taken.
Dataset<-read.table("household_power_consumption.txt", header = TRUE, sep=";", na.strings = "?")
Dataset<-subset(Dataset, Date=="2/2/2007"|Date=="1/2/2007")
#Extra column created psting date and time together
Dataset$DateTime <-paste(Dataset$Date, Dataset$Time)
pn... |
library(staRdom)
### Name: abs_fit_slope
### Title: Fit absorbance data to exponential curve. 'drm' is used for the
### fitting process.
### Aliases: abs_fit_slope
### ** Examples
data(abs_data)
abs_fit_slope(abs_data$wavelength,abs_data$sample1,lim=c(350,400),l_ref=350)
| /data/genthat_extracted_code/staRdom/examples/abs_fit_slope.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 281 | r | library(staRdom)
### Name: abs_fit_slope
### Title: Fit absorbance data to exponential curve. 'drm' is used for the
### fitting process.
### Aliases: abs_fit_slope
### ** Examples
data(abs_data)
abs_fit_slope(abs_data$wavelength,abs_data$sample1,lim=c(350,400),l_ref=350)
|
makeCacheMatrix <- function(x = matrix()) {
invrs <- NULL
setorig <- function(y) {
x <<- y
invrs <<- NULL
}
getorig <- function() x
setinversevalue <- function(inverse) invrs <<- inverse
getinversevalue <- function() invrs
list(set = setorig,
get = getorig,
setinverse = ... | /cachematrix.R | no_license | manjuvegesna/ProgrammingAssignment2 | R | false | false | 649 | r |
makeCacheMatrix <- function(x = matrix()) {
invrs <- NULL
setorig <- function(y) {
x <<- y
invrs <<- NULL
}
getorig <- function() x
setinversevalue <- function(inverse) invrs <<- inverse
getinversevalue <- function() invrs
list(set = setorig,
get = getorig,
setinverse = ... |
\name{Zimmerman}
\alias{Zimmerman}
\docType{data}
\title{Stand Your Ground Simpson's Paradox }
\description{
Data from 220 cases in Florida where a "Stand your ground" defense was used.
}
\format{
A data frame with 220 observations on the following 5 variables.
\describe{
\item{\code{Convicted}}{Was the defenda... | /man/Zimmerman.Rd | permissive | tessington/qsci381 | R | false | false | 1,223 | rd | \name{Zimmerman}
\alias{Zimmerman}
\docType{data}
\title{Stand Your Ground Simpson's Paradox }
\description{
Data from 220 cases in Florida where a "Stand your ground" defense was used.
}
\format{
A data frame with 220 observations on the following 5 variables.
\describe{
\item{\code{Convicted}}{Was the defenda... |
#' Estimates principal component functions by computing eigenfunctions of the covariance function
#'
#' Estimates principal component functions by computing eigenfunctions of the covariance function
#'
#' @param dat functional data set that can be passed to \code{ssfcov2::estimate_cov_function()}. See documentation f... | /R/fpca_ss.R | no_license | dan410/SimStudy_eigenfunction_estimation | R | false | false | 955 | r | #' Estimates principal component functions by computing eigenfunctions of the covariance function
#'
#' Estimates principal component functions by computing eigenfunctions of the covariance function
#'
#' @param dat functional data set that can be passed to \code{ssfcov2::estimate_cov_function()}. See documentation f... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/extract.R
\name{extract_1d}
\alias{extract_1d}
\title{Extract 1d Values}
\usage{
extract_1d(core_table = NULL, input = NULL, data_location = NULL)
}
\arguments{
\item{core_table}{the core table from make_core}
\item{input}{the HIC code for t... | /man/extract_1d.Rd | no_license | CC-HIC/inspectEHR | R | false | true | 621 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/extract.R
\name{extract_1d}
\alias{extract_1d}
\title{Extract 1d Values}
\usage{
extract_1d(core_table = NULL, input = NULL, data_location = NULL)
}
\arguments{
\item{core_table}{the core table from make_core}
\item{input}{the HIC code for t... |
main <- function() {
library(sqldf)
data <- read.csv.sql("household_power_consumption.txt", sql = "select * from file where Date = '1/2/2007' OR Date = '2/2/2007'", eol = "\n", header = TRUE, sep = ";")dat$DateTime <- strptime(paste(dat$Date, dat$Time), "%d/%m/%Y %H:%M")
data$DateTime <- strptime(paste(dat... | /plot2.R | no_license | pnwhitney/ExData_Plotting1 | R | false | false | 525 | r | main <- function() {
library(sqldf)
data <- read.csv.sql("household_power_consumption.txt", sql = "select * from file where Date = '1/2/2007' OR Date = '2/2/2007'", eol = "\n", header = TRUE, sep = ";")dat$DateTime <- strptime(paste(dat$Date, dat$Time), "%d/%m/%Y %H:%M")
data$DateTime <- strptime(paste(dat... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ggplot_util.R
\name{geom_txt}
\alias{geom_txt}
\title{geom_txt}
\usage{
geom_txt(..., family = theme_get()$text$family, size = 3,
colour = "#2b2b2b")
}
\arguments{
\item{...}{Passed to \code{geom_text}.}
\item{family}{Font family. Default... | /man/geom_txt.Rd | no_license | arbelt/azwmisc | R | false | true | 510 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ggplot_util.R
\name{geom_txt}
\alias{geom_txt}
\title{geom_txt}
\usage{
geom_txt(..., family = theme_get()$text$family, size = 3,
colour = "#2b2b2b")
}
\arguments{
\item{...}{Passed to \code{geom_text}.}
\item{family}{Font family. Default... |
library(testthat)
library(BrokenAdaptiveRidge)
test_check("BrokenAdaptiveRidge")
| /tests/testthat.R | permissive | yuxitian/BrokenAdaptiveRidge | R | false | false | 82 | r | library(testthat)
library(BrokenAdaptiveRidge)
test_check("BrokenAdaptiveRidge")
|
library(shiny)
CohortEffect <- function(x1,
x2,
min.meaningful.effect) {
dat <- data.frame(y=c(x1,x2),
d2=c(rep(0, length(x1)), rep(1, length(x2))))
res <- lm(y ~ d2, data=dat)
coefs <- summary(res)$coefficients
effect.mean <- coefs[2,1]
... | /demo/ab/server.R | no_license | shaptonstahl/abtest | R | false | false | 6,607 | r | library(shiny)
CohortEffect <- function(x1,
x2,
min.meaningful.effect) {
dat <- data.frame(y=c(x1,x2),
d2=c(rep(0, length(x1)), rep(1, length(x2))))
res <- lm(y ~ d2, data=dat)
coefs <- summary(res)$coefficients
effect.mean <- coefs[2,1]
... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/geom.mean.R
\name{geom.mean}
\alias{geom.mean}
\title{Geometric Mean}
\usage{
geom.mean(x)
}
\arguments{
\item{x}{a numeric vector for which geometric mean computations shall be performed.}
}
\description{
This function computes the geometric... | /man/geom.mean.Rd | no_license | AcaDemIQ/myTAI | R | false | true | 431 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/geom.mean.R
\name{geom.mean}
\alias{geom.mean}
\title{Geometric Mean}
\usage{
geom.mean(x)
}
\arguments{
\item{x}{a numeric vector for which geometric mean computations shall be performed.}
}
\description{
This function computes the geometric... |
End of preview. Expand in Data Studio
The R code only of https://huggingface.co/datasets/bigcode/the-stack-v2, downloaded content and ready to use.
- Downloads last month
- 10