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 |
|---|---|---|---|---|---|---|---|---|---|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mainCode.R
\name{fit.AENOPM}
\alias{fit.AENOPM}
\title{The function to fit OPM algorithm for variable selection under two data-types with Adaptive elastic net in Step I and OPM in step 2}
\usage{
fit.AENOPM(Y, X, LAMBDA, ncores, test, train, ... | /OPMpackage/man/fit.AENOPM.Rd | no_license | royarkaprava/OPM | R | false | true | 1,202 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mainCode.R
\name{fit.AENOPM}
\alias{fit.AENOPM}
\title{The function to fit OPM algorithm for variable selection under two data-types with Adaptive elastic net in Step I and OPM in step 2}
\usage{
fit.AENOPM(Y, X, LAMBDA, ncores, test, train, ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/liouville.R
\name{theta.bci}
\alias{theta.bci}
\title{Parametric bootstrap confidence interval for the parameter \code{theta} for Liouville copula}
\usage{
theta.bci(B = 1999, family, alphavec, n, theta.hat, quant = c(0.025,
0.975), silent ... | /lcopula/man/theta.bci.Rd | no_license | akhikolla/InformationHouse | R | false | true | 2,152 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/liouville.R
\name{theta.bci}
\alias{theta.bci}
\title{Parametric bootstrap confidence interval for the parameter \code{theta} for Liouville copula}
\usage{
theta.bci(B = 1999, family, alphavec, n, theta.hat, quant = c(0.025,
0.975), silent ... |
#Exercise 1
print(Sys.time())
#Exercise 2
#Exercise 3
#Exercise 4
#Exercise 5 | /module4ex.R | no_license | chiragkulkarni3/hello-world | R | false | false | 82 | r |
#Exercise 1
print(Sys.time())
#Exercise 2
#Exercise 3
#Exercise 4
#Exercise 5 |
#' Get the marker genes for each cluster
#'
#' Get the marker genes for each cluster and report their 1-normalized expression value.
#'
#' @param counts_data a matrix of expression values for each cell (rows) and gene (columns) which will be normalized and
#' @param cluster_labels a vector of cluster labels
#' @param... | /R/MarkerGenes.R | no_license | adamlmaclean/RSoptSC | R | false | false | 4,840 | r | #' Get the marker genes for each cluster
#'
#' Get the marker genes for each cluster and report their 1-normalized expression value.
#'
#' @param counts_data a matrix of expression values for each cell (rows) and gene (columns) which will be normalized and
#' @param cluster_labels a vector of cluster labels
#' @param... |
#' Choose months
#'
#' When chooseday() is asked for multiple months, they are selected and combined into a new data frame for further processing
#'
#' @param d dataframe that day is to be selected from. date time information must be POSIXct in column labled "date"
#' @param mymonth month as a vector of integers, mon... | /R/func_choosemonths.R | no_license | nemochina2008/wsdmiscr | R | false | false | 668 | r | #' Choose months
#'
#' When chooseday() is asked for multiple months, they are selected and combined into a new data frame for further processing
#'
#' @param d dataframe that day is to be selected from. date time information must be POSIXct in column labled "date"
#' @param mymonth month as a vector of integers, mon... |
##Merges the training and the test sets to create one data set.
##Extracts only the measurements on the mean and standard deviation for each measurement.
##Uses descriptive activity names to name the activities in the data set
##Appropriately labels the data set with descriptive variable names.
##From the data set in... | /run_analysis.R | no_license | jrkkota/GettingAndDataCleaning | R | false | false | 3,444 | r | ##Merges the training and the test sets to create one data set.
##Extracts only the measurements on the mean and standard deviation for each measurement.
##Uses descriptive activity names to name the activities in the data set
##Appropriately labels the data set with descriptive variable names.
##From the data set in... |
context("Variances")
test_that("Variances", {
data <- integration.testdata1()
vars <- excursions.variances(data$L, max.threads=1)
v = diag(solve(data$Q))
expect_equal(vars,v,tolerance=1e-7)
})
test_that("Variances Q and L", {
data <- integration.testdata1()
v1 <- excursions.variances(L = data$L, max.threa... | /excursions/tests/testthat/test.variances.R | no_license | ingted/R-Examples | R | false | false | 422 | r | context("Variances")
test_that("Variances", {
data <- integration.testdata1()
vars <- excursions.variances(data$L, max.threads=1)
v = diag(solve(data$Q))
expect_equal(vars,v,tolerance=1e-7)
})
test_that("Variances Q and L", {
data <- integration.testdata1()
v1 <- excursions.variances(L = data$L, max.threa... |
library(data.table)
library(reshape2)
library(ggplot2)
library(dplyr)
# source("code/useful R/libraries_and_themes_1_1025.R")
setwd("/Users/Michel/Desktop/Research/MFA/code/")
theme_set(figure_theme)
options(stringsAsFactors = FALSE)
growth.dat <- read.table("../MFA code/first_timecourses/PCV_timecourses_1_and_2.csv"... | /fit_growthcurve.R | no_license | michelnofal/MFA_project | R | false | false | 1,546 | r | library(data.table)
library(reshape2)
library(ggplot2)
library(dplyr)
# source("code/useful R/libraries_and_themes_1_1025.R")
setwd("/Users/Michel/Desktop/Research/MFA/code/")
theme_set(figure_theme)
options(stringsAsFactors = FALSE)
growth.dat <- read.table("../MFA code/first_timecourses/PCV_timecourses_1_and_2.csv"... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/foo.R
\name{plot.profile.PrevMap}
\alias{plot.profile.PrevMap}
\title{Plot of the profile log-likelihood for the covariance parameters of the Matern function}
\usage{
\method{plot}{profile.PrevMap}(x, log.scale = FALSE, plot.spline.profile = ... | /man/plot.profile.PrevMap.Rd | no_license | cran/PrevMap | R | false | true | 1,241 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/foo.R
\name{plot.profile.PrevMap}
\alias{plot.profile.PrevMap}
\title{Plot of the profile log-likelihood for the covariance parameters of the Matern function}
\usage{
\method{plot}{profile.PrevMap}(x, log.scale = FALSE, plot.spline.profile = ... |
# IGraph R package
# Copyright (C) 2005-2012 Gabor Csardi <csardi.gabor@gmail.com>
# 334 Harvard street, Cambridge, MA 02139 USA
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation... | /CRAN/contrib/igraph/R/iterators.R | no_license | PRL-PRG/dyntrace-instrumented-packages | R | false | false | 50,724 | r |
# IGraph R package
# Copyright (C) 2005-2012 Gabor Csardi <csardi.gabor@gmail.com>
# 334 Harvard street, Cambridge, MA 02139 USA
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation... |
ROOT_URL <- "http://production.shippingapis.com/ShippingAPI.dll?API=Verify&XML="
request_template <- list(
AddressValidateRequest = list(
)
)
#' Recompose address to follow USPS API specs
#'
#' @param usr
#' @param street
#' @param city
#' @param state
#' @param zip
#'
#' @return
#' @export
#'
#' @examples
#' co... | /R/usps.R | no_license | steve-liang/addressR | R | false | false | 2,732 | r |
ROOT_URL <- "http://production.shippingapis.com/ShippingAPI.dll?API=Verify&XML="
request_template <- list(
AddressValidateRequest = list(
)
)
#' Recompose address to follow USPS API specs
#'
#' @param usr
#' @param street
#' @param city
#' @param state
#' @param zip
#'
#' @return
#' @export
#'
#' @examples
#' co... |
#' Package/R News
#'
#' Find out news on a package or R.
#'
#' @param package Name of package (default is to see news for R).
#' @seealso \code{\link[utils]{news}}
#' @keywords news packages
#' @export
#' @examples
#' p_news()
#' p_news(lattice)
#' ## Grab specific version subsets
#' subset(p_news(lattice)... | /pacman/R/p_news.R | no_license | ingted/R-Examples | R | false | false | 783 | r | #' Package/R News
#'
#' Find out news on a package or R.
#'
#' @param package Name of package (default is to see news for R).
#' @seealso \code{\link[utils]{news}}
#' @keywords news packages
#' @export
#' @examples
#' p_news()
#' p_news(lattice)
#' ## Grab specific version subsets
#' subset(p_news(lattice)... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/page_records.R
\name{delete_record}
\alias{delete_record}
\title{Delete record}
\usage{
delete_record(server_name, profile_id, access_token, page_id, record_id)
}
\arguments{
\item{server_name}{String of the iFormBuilder server name.}
\item{... | /man/delete_record.Rd | no_license | bdevoe/iformr | R | false | true | 722 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/page_records.R
\name{delete_record}
\alias{delete_record}
\title{Delete record}
\usage{
delete_record(server_name, profile_id, access_token, page_id, record_id)
}
\arguments{
\item{server_name}{String of the iFormBuilder server name.}
\item{... |
scopeFun <- function() {
me <- 15
was <- m<caret>e + me
}
| /testData/rename/renameVariableInFunctionCollisions.R | permissive | JetBrains/Rplugin | R | false | false | 63 | r | scopeFun <- function() {
me <- 15
was <- m<caret>e + me
}
|
# Calculate motif log2 fold changes and differentially expressed proteins.
#
# The purpose of this script is to calculate log2 fold changes for all conditions
# compared to ctrl_0, using limma.
# This script is intended as the starting point for other scripts using RPPA
# L2FCs and or DE proteins
library(tidyverse)
#l... | /R/MDD_motifs_limma.R | no_license | MEP-LINCS/MDD | R | false | false | 2,490 | r | # Calculate motif log2 fold changes and differentially expressed proteins.
#
# The purpose of this script is to calculate log2 fold changes for all conditions
# compared to ctrl_0, using limma.
# This script is intended as the starting point for other scripts using RPPA
# L2FCs and or DE proteins
library(tidyverse)
#l... |
#' Convert numeric variable to NPS categorical variable
#'
#' Returns a categorical variable with default values over 1, 2, and 3.
#' Suited for running multinomial logistic regression.
#' To calculate the NPS score, use `as_nps()`.
#'
#' @param x Numeric variable to pass through. Valid range is 0 to 10 inclusive, o... | /R/as_nps_cat.R | no_license | martinctc/surveytoolbox | R | false | false | 1,092 | r | #' Convert numeric variable to NPS categorical variable
#'
#' Returns a categorical variable with default values over 1, 2, and 3.
#' Suited for running multinomial logistic regression.
#' To calculate the NPS score, use `as_nps()`.
#'
#' @param x Numeric variable to pass through. Valid range is 0 to 10 inclusive, o... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/focus_on.R
\name{focus_on}
\alias{focus_on}
\title{Place certain access details more to the fore}
\usage{
focus_on(agent, tbl_name = NULL, file_name = NULL, col_types = NULL,
db_type = NULL, initial_sql = NULL, brief = NULL,
creds_file = ... | /man/focus_on.Rd | permissive | elong0527/pointblank | R | false | true | 3,504 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/focus_on.R
\name{focus_on}
\alias{focus_on}
\title{Place certain access details more to the fore}
\usage{
focus_on(agent, tbl_name = NULL, file_name = NULL, col_types = NULL,
db_type = NULL, initial_sql = NULL, brief = NULL,
creds_file = ... |
# Matthew J. Keefe
# June 8, 2020
# TidyTuesday -- African American Achievements
# Load in Libraries and Data ----------------------------------------------
library(tidyverse)
library(skimr)
firsts <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/master/data/2020/2020-06-09/firsts.cs... | /2020/2020-06-09/african_american_achievements.R | no_license | mjkeefe/tidytuesday | R | false | false | 1,953 | r | # Matthew J. Keefe
# June 8, 2020
# TidyTuesday -- African American Achievements
# Load in Libraries and Data ----------------------------------------------
library(tidyverse)
library(skimr)
firsts <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/master/data/2020/2020-06-09/firsts.cs... |
library(trenaSNP)
library(RUnit)
#------------------------------------------------------------------------------------------------------------------------
printf <- function(...) print(noquote(sprintf(...)))
#---------------------------------------------------------------------------------------------------------------... | /inst/unitTests/test_trenaSNP.R | no_license | paul-shannon/trenaSNP | R | false | false | 4,715 | r | library(trenaSNP)
library(RUnit)
#------------------------------------------------------------------------------------------------------------------------
printf <- function(...) print(noquote(sprintf(...)))
#---------------------------------------------------------------------------------------------------------------... |
\name{covid_dates}
\alias{covid_dates}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{covid_dates
%% ~~function to do ... ~~
}
\description{
%% ~~ A concise (1-5 lines) description of what the function does. ~~
}
\usage{
covid_dates(x)
}
%- maybe also 'usage' for other objects documented here.
... | /man/covid_dates.Rd | no_license | DEQrshojin/covid19 | R | false | false | 1,287 | rd | \name{covid_dates}
\alias{covid_dates}
%- Also NEED an '\alias' for EACH other topic documented here.
\title{covid_dates
%% ~~function to do ... ~~
}
\description{
%% ~~ A concise (1-5 lines) description of what the function does. ~~
}
\usage{
covid_dates(x)
}
%- maybe also 'usage' for other objects documented here.
... |
Sys.setenv(PATH=paste("/home/yannick/bin/anaconda3/bin", Sys.getenv("PATH"), sep = ":"))
keras::use_condaenv("r-tensorflow")
library(keras)
mnist <- dataset_mnist()
x_train <- mnist$train$x
y_train <- mnist$train$y
x_test <- mnist$test$x
y_test <- mnist$test$y
# reshape
dim(x_train) <- c(nrow(x_train), 784)
dim(x_t... | /R/keras_R_test_mlp.R | no_license | yama1968/Spikes | R | false | false | 1,033 | r |
Sys.setenv(PATH=paste("/home/yannick/bin/anaconda3/bin", Sys.getenv("PATH"), sep = ":"))
keras::use_condaenv("r-tensorflow")
library(keras)
mnist <- dataset_mnist()
x_train <- mnist$train$x
y_train <- mnist$train$y
x_test <- mnist$test$x
y_test <- mnist$test$y
# reshape
dim(x_train) <- c(nrow(x_train), 784)
dim(x_t... |
# plot biomass time series facet wrapped by species
plotB <- function(dat, truedat=NULL){
svbio <- dat %>% filter(variable=="biomass")
svcv <- dat %>% filter(variable=="cv")
ggplot() +
geom_line(data=svbio, aes(x=year,y=value, color="Survey Biomass"),
alpha = 10/10) +
{if(!is.null(tru... | /WGSAM/ICES_WGSAM_10Oct2022/R/simplots.R | no_license | NOAA-EDAB/presentations | R | false | false | 3,228 | r | # plot biomass time series facet wrapped by species
plotB <- function(dat, truedat=NULL){
svbio <- dat %>% filter(variable=="biomass")
svcv <- dat %>% filter(variable=="cv")
ggplot() +
geom_line(data=svbio, aes(x=year,y=value, color="Survey Biomass"),
alpha = 10/10) +
{if(!is.null(tru... |
cleanup <- function() {
# check if the UCI data exists. if not create a directory and downloaded
# the file. unzip file into directory.
if(!file.exists("./UCIdata")) {
dir.create("./UCIdata")
fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip... | /run_analysis.R | no_license | gurlsam/coursera | R | false | false | 3,189 | r | cleanup <- function() {
# check if the UCI data exists. if not create a directory and downloaded
# the file. unzip file into directory.
if(!file.exists("./UCIdata")) {
dir.create("./UCIdata")
fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip... |
#Load SNP differential missingness file and generate distribution
b.frq <- read.table("clean_inds_example_test_missing.missing",header=T)
b.frq$logP = log10(b.frq$P)
pdf("plots/diffmiss_plot.pdf")
plot(ecdf(b.frq$logP), xlim=c(-10,0),ylim=c(0,1),pch=20, main="Distribution of differential missingness P-values", xlab="lo... | /diffmiss_plot.R | no_license | jsan4christ/gwas_usecases | R | false | false | 392 | r | #Load SNP differential missingness file and generate distribution
b.frq <- read.table("clean_inds_example_test_missing.missing",header=T)
b.frq$logP = log10(b.frq$P)
pdf("plots/diffmiss_plot.pdf")
plot(ecdf(b.frq$logP), xlim=c(-10,0),ylim=c(0,1),pch=20, main="Distribution of differential missingness P-values", xlab="lo... |
# Biostats in epidemiology
# ch 14 work
# 14.2 --------------------------------------------------------------------
# sample size for closed cohort study
ss.closed.chort <- function(pi2, delta, sig.level = 0.05, power = 0.80, rho = 1,
type=c("RD","RR","OR")){
type <- match.arg... | /data-raw/ch_14_work.R | no_license | clayford/bme | R | false | false | 16,505 | r | # Biostats in epidemiology
# ch 14 work
# 14.2 --------------------------------------------------------------------
# sample size for closed cohort study
ss.closed.chort <- function(pi2, delta, sig.level = 0.05, power = 0.80, rho = 1,
type=c("RD","RR","OR")){
type <- match.arg... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/reportPi0.R
\name{reportPi0}
\alias{reportPi0}
\title{Get pi0 from P-values}
\usage{
reportPi0(ps)
}
\arguments{
\item{ps}{a vector, data.frame or matrix of pvalues}
}
\value{
a vector (if is.numeric(ps)) or a
matrix of pi0 and the number of ... | /man/reportPi0.Rd | no_license | jtlovell/RNAseqDE | R | false | true | 618 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/reportPi0.R
\name{reportPi0}
\alias{reportPi0}
\title{Get pi0 from P-values}
\usage{
reportPi0(ps)
}
\arguments{
\item{ps}{a vector, data.frame or matrix of pvalues}
}
\value{
a vector (if is.numeric(ps)) or a
matrix of pi0 and the number of ... |
library(valottery)
### Name: power.ball
### Title: Power Ball
### Aliases: power.ball
### Keywords: datasets
### ** Examples
## According to game rules, the powerball is numbered 1 - 35,
## but apparently there were times when it went up to 39
i <- power.ball$powerball > 35
any(i)
sum(i)
power.ball$powerball[i]
| /data/genthat_extracted_code/valottery/examples/power.ball.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 320 | r | library(valottery)
### Name: power.ball
### Title: Power Ball
### Aliases: power.ball
### Keywords: datasets
### ** Examples
## According to game rules, the powerball is numbered 1 - 35,
## but apparently there were times when it went up to 39
i <- power.ball$powerball > 35
any(i)
sum(i)
power.ball$powerball[i]
|
#load packages from library
library(tidyverse);library(rvest);library(magrittr);library(XML);library(janitor);library(stringr);library(rlang);library(readxl);
#player id map
id_map <- read.csv('http://crunchtimebaseball.com/master.csv', stringsAsFactors = F) %>% select(fg_name, fg_pos)
pos_fg <- id_map %>% select(fg_n... | /mlb_source.R | no_license | cuddjim/mlb | R | false | false | 2,939 | r | #load packages from library
library(tidyverse);library(rvest);library(magrittr);library(XML);library(janitor);library(stringr);library(rlang);library(readxl);
#player id map
id_map <- read.csv('http://crunchtimebaseball.com/master.csv', stringsAsFactors = F) %>% select(fg_name, fg_pos)
pos_fg <- id_map %>% select(fg_n... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Lasso_pre.R
\name{Lasso_pre}
\alias{Lasso_pre}
\title{Lasso predictions}
\usage{
Lasso_pre(
variabledf,
alpha = 1,
y_varname = c("day_value", "night_value", "value_mean"),
training,
test,
grepstring
)
}
\description{
Lasso predict... | /man/Lasso_pre.Rd | no_license | mengluchu/APMtools | R | false | true | 327 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Lasso_pre.R
\name{Lasso_pre}
\alias{Lasso_pre}
\title{Lasso predictions}
\usage{
Lasso_pre(
variabledf,
alpha = 1,
y_varname = c("day_value", "night_value", "value_mean"),
training,
test,
grepstring
)
}
\description{
Lasso predict... |
#' Copy a local project to a docklet.
#'
#' Currently a work in progress.
#'
#' @param droplet A docklet, created with \code{\link{docklet_create}}.
#' Must have docker installed.
#' @param project Path to a rstudio + packrat project.
#' @param user,password Default username and password for RStudio
#' @param verbose... | /inst/ignore/docklet_packrat.R | permissive | pachadotdev/analogsea | R | false | false | 1,386 | r | #' Copy a local project to a docklet.
#'
#' Currently a work in progress.
#'
#' @param droplet A docklet, created with \code{\link{docklet_create}}.
#' Must have docker installed.
#' @param project Path to a rstudio + packrat project.
#' @param user,password Default username and password for RStudio
#' @param verbose... |
make_stan_data <- function(stanmod_name, sample_data, pop_cluster_data,
sampled_cluster_data) {
# stanmod_name -- string of the name of the stan model to be used
# sample_data -- unit-level data frame of the sampled data
# pop_cluster_data -- cluster-level data frame for all pop cluster... | /src/simulation/make_stan_data.R | no_license | smmakela/cluster_sampling | R | false | false | 11,433 | r | make_stan_data <- function(stanmod_name, sample_data, pop_cluster_data,
sampled_cluster_data) {
# stanmod_name -- string of the name of the stan model to be used
# sample_data -- unit-level data frame of the sampled data
# pop_cluster_data -- cluster-level data frame for all pop cluster... |
#' @title PrEP Module
#'
#' @description Module function for implementation and uptake of pre-exposure
#' prophylaxis (PrEP) to prevent HIV infection.
#'
#' @inheritParams aging_msm
#'
#' @keywords module msm
#'
#' @export
#'
prep_msm <- function(dat, at) {
if (at < dat$param$prep.start) {
return(d... | /tempR/mod.prep.R | no_license | dth2/EpiModelHIV_SHAMP | R | false | false | 4,048 | r |
#' @title PrEP Module
#'
#' @description Module function for implementation and uptake of pre-exposure
#' prophylaxis (PrEP) to prevent HIV infection.
#'
#' @inheritParams aging_msm
#'
#' @keywords module msm
#'
#' @export
#'
prep_msm <- function(dat, at) {
if (at < dat$param$prep.start) {
return(d... |
#Exercise 3.3
#source('Desktop/ML/EXERCISE_3/loadImage.R')
#source('Desktop/ML/EXERCISE_3/load_dataset.R')
#source('D:/Documents/GitHub/Machine_Learning/EXERCISE_3/loadImage.R')
#source('D:/Documents/GitHub/Machine_Learning/EXERCISE_3/load_dataset.R')
train<-dataset[1:(nrow(dataset)/2),-1]
test<-dataset[4001:nrow(data... | /EXERCISE_3/exercise3_3.R | no_license | elisabetta42/Machine_Learning | R | false | false | 1,388 | r | #Exercise 3.3
#source('Desktop/ML/EXERCISE_3/loadImage.R')
#source('Desktop/ML/EXERCISE_3/load_dataset.R')
#source('D:/Documents/GitHub/Machine_Learning/EXERCISE_3/loadImage.R')
#source('D:/Documents/GitHub/Machine_Learning/EXERCISE_3/load_dataset.R')
train<-dataset[1:(nrow(dataset)/2),-1]
test<-dataset[4001:nrow(data... |
estimateDensity2D = function(X,Y,DensityEstimation="SDH", SampleSize, na.rm=FALSE, NoBinsOrPareto=NULL) {
# estimateDensity2D
# Estimates densities for two-dimensional data with the given estimation type
#
# INPUT
# X [1:n] numerical vector of first feature
# Y ... | /R/estimateDensity2D.R | no_license | cran/DataVisualizations | R | false | false | 4,110 | r | estimateDensity2D = function(X,Y,DensityEstimation="SDH", SampleSize, na.rm=FALSE, NoBinsOrPareto=NULL) {
# estimateDensity2D
# Estimates densities for two-dimensional data with the given estimation type
#
# INPUT
# X [1:n] numerical vector of first feature
# Y ... |
## Declaring libraries
library(shiny)
library(ggplot2)
library(dplyr)
source("analysis.R")
## Defining UI
ui <- navbarPage("Global Agricultural Production", theme = "project.css",
## tab 1 lets users select a year and an item and displays a choropleth
## map showing how much each country produces
... | /ui.R | permissive | rosejao/collab-project | R | false | false | 8,623 | r | ## Declaring libraries
library(shiny)
library(ggplot2)
library(dplyr)
source("analysis.R")
## Defining UI
ui <- navbarPage("Global Agricultural Production", theme = "project.css",
## tab 1 lets users select a year and an item and displays a choropleth
## map showing how much each country produces
... |
library(class)
library(caret)
library(gmodels)
zoo <- read.csv(file.choose()) #Zoo.csv
View(zoo)
str(zoo)
anyNA(zoo)
dim(zoo)
zoo1 <- zoo[,2:18]
View(zoo1)
# rownames(zoo) <- zoo$animal.name
zoo1$hair <- as.factor(zoo1$hair)
zoo1$feathers <- as.factor(zoo1$feathers)
zoo1$eggs <- as.factor(zoo1$eg... | /KNN - Code/zoo_KNN.R | no_license | abheeshta97/ExcelR | R | false | false | 1,400 | r | library(class)
library(caret)
library(gmodels)
zoo <- read.csv(file.choose()) #Zoo.csv
View(zoo)
str(zoo)
anyNA(zoo)
dim(zoo)
zoo1 <- zoo[,2:18]
View(zoo1)
# rownames(zoo) <- zoo$animal.name
zoo1$hair <- as.factor(zoo1$hair)
zoo1$feathers <- as.factor(zoo1$feathers)
zoo1$eggs <- as.factor(zoo1$eg... |
boxplot <- ggplot(airquality, aes(x = as.factor(Month), y = Ozone)) + geom_boxplot()
plot1 <- ggplot(mtcars, aes(x = mpg, y = disp, col = hp)) + geom_point()
| /descriptions_stat_graphics.R | no_license | anastasiiakhil/Data_analysis | R | false | false | 159 | r | boxplot <- ggplot(airquality, aes(x = as.factor(Month), y = Ozone)) + geom_boxplot()
plot1 <- ggplot(mtcars, aes(x = mpg, y = disp, col = hp)) + geom_point()
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/jamenrich-communities-nodegroups.R
\name{communities2nodegroups}
\alias{communities2nodegroups}
\title{Convert communities object to nodegroups list format}
\usage{
communities2nodegroups(wc, ...)
}
\arguments{
\item{wc}{\code{communities} ob... | /man/communities2nodegroups.Rd | no_license | jmw86069/multienrichjam | R | false | true | 2,719 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/jamenrich-communities-nodegroups.R
\name{communities2nodegroups}
\alias{communities2nodegroups}
\title{Convert communities object to nodegroups list format}
\usage{
communities2nodegroups(wc, ...)
}
\arguments{
\item{wc}{\code{communities} ob... |
#Hyeongwan Seo
library(gridExtra) # 라이브러리를 로드하지 못하면 install.packages("gridExtra")를 해야함.
library(ggplot2) #라이브러리를 로드하지 못하면 install.packages("ggplot2")를 해야함.
dataset <- read.csv(file="CPU/cpu_statistics.csv", as.is=TRUE)
dataset$Time <- strptime(format="%d-%m-%Y %H:%M:%S %z", dataset$Timestamp, tz="GMT")
# y축의 max 값을... | /CPU/United_CPU_graph.R | no_license | sypark9646/linux_system_usage_graph | R | false | false | 1,514 | r | #Hyeongwan Seo
library(gridExtra) # 라이브러리를 로드하지 못하면 install.packages("gridExtra")를 해야함.
library(ggplot2) #라이브러리를 로드하지 못하면 install.packages("ggplot2")를 해야함.
dataset <- read.csv(file="CPU/cpu_statistics.csv", as.is=TRUE)
dataset$Time <- strptime(format="%d-%m-%Y %H:%M:%S %z", dataset$Timestamp, tz="GMT")
# y축의 max 값을... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{rates}
\alias{rates}
\title{CEFAGE-UE journals' rates}
\format{A data frame with 6 rows (rates) and 2 variables:
\describe{
\item{rate}{Rate value.}
\item{description}{Rate description.}
}}
\source{
\url{http:/... | /man/rates.Rd | no_license | ramiromagno/cjr | R | false | true | 780 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{rates}
\alias{rates}
\title{CEFAGE-UE journals' rates}
\format{A data frame with 6 rows (rates) and 2 variables:
\describe{
\item{rate}{Rate value.}
\item{description}{Rate description.}
}}
\source{
\url{http:/... |
### Trigonometry + Euler Method
# Libraries
library(tidyverse)
library(scales)
# Creating data
sin_df = do.call(rbind, apply(as.matrix(seq(0, 1, 0.01)), 1, FUN = function(x) {
return(data.frame(x_val = pi*x, y = sin(2*pi*x)))}))
# Creating pi ticks function
pi_scales <- math_format(.x * pi, format = function(x) x ... | /euler_trig.R | no_license | b-thi/ODEs | R | false | false | 605 | r | ### Trigonometry + Euler Method
# Libraries
library(tidyverse)
library(scales)
# Creating data
sin_df = do.call(rbind, apply(as.matrix(seq(0, 1, 0.01)), 1, FUN = function(x) {
return(data.frame(x_val = pi*x, y = sin(2*pi*x)))}))
# Creating pi ticks function
pi_scales <- math_format(.x * pi, format = function(x) x ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/prob_func.R
\name{inf_sum_MGF}
\alias{inf_sum_MGF}
\title{Summation SMNG moment generating function}
\usage{
inf_sum_MGF(r, lambda, delta, gamma, beta, rel_tol)
}
\description{
Function that adds terms to the infinite sum of the SMNG moment g... | /BayesLN/man/inf_sum_MGF.Rd | no_license | akhikolla/ClusterTests | R | false | true | 443 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/prob_func.R
\name{inf_sum_MGF}
\alias{inf_sum_MGF}
\title{Summation SMNG moment generating function}
\usage{
inf_sum_MGF(r, lambda, delta, gamma, beta, rel_tol)
}
\description{
Function that adds terms to the infinite sum of the SMNG moment g... |
library(markovchain)
### Name: predictiveDistribution
### Title: Function to compute the probability of observing a new data set,
### given a data set
### Aliases: predictiveDistribution
### ** Examples
sequence<-c("a", "b", "a", "a", "a", "a", "b", "a", "b", "a", "b", "a", "a",
"b", "b", "b", "a")
hyperMatrix<-... | /data/genthat_extracted_code/markovchain/examples/predictiveDistribution.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 643 | r | library(markovchain)
### Name: predictiveDistribution
### Title: Function to compute the probability of observing a new data set,
### given a data set
### Aliases: predictiveDistribution
### ** Examples
sequence<-c("a", "b", "a", "a", "a", "a", "b", "a", "b", "a", "b", "a", "a",
"b", "b", "b", "a")
hyperMatrix<-... |
setMethod(f="initialize",
signature="coastline",
definition=function(.Object, longitude=NULL, latitude=NULL, filename="", fillable=FALSE) {
.Object@data$longitude <- longitude
.Object@data$latitude <- latitude
.Object@metadata$filename <- filename
... | /oce/R/coastline.R | no_license | ingted/R-Examples | R | false | false | 38,356 | r | setMethod(f="initialize",
signature="coastline",
definition=function(.Object, longitude=NULL, latitude=NULL, filename="", fillable=FALSE) {
.Object@data$longitude <- longitude
.Object@data$latitude <- latitude
.Object@metadata$filename <- filename
... |
## Script Name: plot6.R
## Libraries needed:
library(plyr)
library(ggplot2)
library(grid)
setwd("./project2")
## Step 1: read in the data
NEI <- readRDS("expdata_prj2/summarySCC_PM25.rds")
SCC <- readRDS("expdata_prj2/Source_Classification_Code.rds")
## Step 2: check the levels for types of vehicles d... | /plot6.R | no_license | RajivShrestha/ExData_Plotting2 | R | false | false | 1,728 | r | ## Script Name: plot6.R
## Libraries needed:
library(plyr)
library(ggplot2)
library(grid)
setwd("./project2")
## Step 1: read in the data
NEI <- readRDS("expdata_prj2/summarySCC_PM25.rds")
SCC <- readRDS("expdata_prj2/Source_Classification_Code.rds")
## Step 2: check the levels for types of vehicles d... |
############################ read input data ############################
data <- read.csv(file = "household_power_consumption.txt", sep=";", header = T)
############################ data type conversions ############################
str(data)
dim(data)
# [1] 2075259 10
head(data)
tail(data)
#create a column fo... | /plot3.r | no_license | fpaster/ExData_Plotting1 | R | false | false | 1,880 | r | ############################ read input data ############################
data <- read.csv(file = "household_power_consumption.txt", sep=";", header = T)
############################ data type conversions ############################
str(data)
dim(data)
# [1] 2075259 10
head(data)
tail(data)
#create a column fo... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/modify_columns.R
\name{cols_align}
\alias{cols_align}
\title{Set the alignment of columns}
\usage{
cols_align(
data,
align = c("auto", "left", "center", "right"),
columns = everything()
)
}
\arguments{
\item{data}{A table object that is... | /man/cols_align.Rd | permissive | jooyoungseo/gt | R | false | true | 2,800 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/modify_columns.R
\name{cols_align}
\alias{cols_align}
\title{Set the alignment of columns}
\usage{
cols_align(
data,
align = c("auto", "left", "center", "right"),
columns = everything()
)
}
\arguments{
\item{data}{A table object that is... |
datadir<-"~/genomeanalysis_project/analyses/09_htseq"
sampleFile <- c("bh_1.txt", "bh_2.txt", "bh_3.txt", "se_1.txt", "se_2.txt", "se_3.txt")
sampleName <- c("bh_1", "bh_2", "bh_3", "se_1", "se_2", "se_3")
condition <- c("bh", "bh", "bh", "se", "se", "se")
seqData <- data.frame(sampleName, sampleFile, condition)
lib... | /codes/10_03_Deseq.r | no_license | oliviamikaela/genomeanalysis_project | R | false | false | 1,232 | r | datadir<-"~/genomeanalysis_project/analyses/09_htseq"
sampleFile <- c("bh_1.txt", "bh_2.txt", "bh_3.txt", "se_1.txt", "se_2.txt", "se_3.txt")
sampleName <- c("bh_1", "bh_2", "bh_3", "se_1", "se_2", "se_3")
condition <- c("bh", "bh", "bh", "se", "se", "se")
seqData <- data.frame(sampleName, sampleFile, condition)
lib... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/headers.r
\name{headers}
\alias{headers}
\title{Extract the headers from a response}
\usage{
headers(x)
}
\arguments{
\item{x}{A request object}
}
\description{
Extract the headers from a response
}
\examples{
r <- GET("http://httpbin... | /Data Science/Miscellaenous/Misc - httr info/man/headers.Rd | no_license | Mike-Kuklinski/Coursera | R | false | false | 427 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/headers.r
\name{headers}
\alias{headers}
\title{Extract the headers from a response}
\usage{
headers(x)
}
\arguments{
\item{x}{A request object}
}
\description{
Extract the headers from a response
}
\examples{
r <- GET("http://httpbin... |
shinyUI(pageWithSidebar(
headerPanel("Message sending, with message hander in inline Javascript"),
sidebarPanel(
sliderInput("controller", "Controller:",
min = 1, max = 20, value = 15)
),
mainPanel(
# Put this script in the header, and use the HTML() function to make
# sure that ch... | /message-handler-inline/ui.r | no_license | takewiki/testapp | R | false | false | 546 | r | shinyUI(pageWithSidebar(
headerPanel("Message sending, with message hander in inline Javascript"),
sidebarPanel(
sliderInput("controller", "Controller:",
min = 1, max = 20, value = 15)
),
mainPanel(
# Put this script in the header, and use the HTML() function to make
# sure that ch... |
\name{coxph.detail}
\alias{coxph.detail}
\title{
Details of a Cox Model Fit
}
\description{
Returns the individual contributions to the first and second derivative
matrix, at each unique event time.
}
\usage{
coxph.detail(object, riskmat=FALSE, rorder=c("data", "time"))
}
\arguments{
\item{object}{
a Cox model obje... | /man/coxph.detail.Rd | no_license | cran/survival | R | false | false | 3,169 | rd | \name{coxph.detail}
\alias{coxph.detail}
\title{
Details of a Cox Model Fit
}
\description{
Returns the individual contributions to the first and second derivative
matrix, at each unique event time.
}
\usage{
coxph.detail(object, riskmat=FALSE, rorder=c("data", "time"))
}
\arguments{
\item{object}{
a Cox model obje... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/03_alignment.R
\name{picard.reorder}
\alias{picard.reorder}
\title{picard.reorder}
\usage{
picard.reorder(fns.bam, output.dir, sample.name, ref.fa, ALLOW_INCOMPLETE_DICT_CONCORDANCE=FALSE, ALLOW_CONTIG_LENGTH_DISCORDANCE=FALSE, CREATE_INDEX=T... | /man/picard.reorder.Rd | no_license | Gster963/SEQprocess | R | false | true | 1,731 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/03_alignment.R
\name{picard.reorder}
\alias{picard.reorder}
\title{picard.reorder}
\usage{
picard.reorder(fns.bam, output.dir, sample.name, ref.fa, ALLOW_INCOMPLETE_DICT_CONCORDANCE=FALSE, ALLOW_CONTIG_LENGTH_DISCORDANCE=FALSE, CREATE_INDEX=T... |
#homework
#q1
pvs <- numeric(1000)
set.seed(1234)
for(i in 1:1000){
y1 <- rnorm(n = 50, mean = 100, sd = 15)
y2 <- rnorm(n = 50, mean = 100, sd = 25)
treat <- rep(c("control", "treatement"), each = 50)
math <- c(y1, y2)
dat <- data.frame(treat, math)
res <- t.test(math ~ treat, data = dat)
pvs[i] <- res$p... | /homework1.R | no_license | jhdn8/Homework_Hwang | R | false | false | 765 | r | #homework
#q1
pvs <- numeric(1000)
set.seed(1234)
for(i in 1:1000){
y1 <- rnorm(n = 50, mean = 100, sd = 15)
y2 <- rnorm(n = 50, mean = 100, sd = 25)
treat <- rep(c("control", "treatement"), each = 50)
math <- c(y1, y2)
dat <- data.frame(treat, math)
res <- t.test(math ~ treat, data = dat)
pvs[i] <- res$p... |
#' Summoner's recent match information
#'
#' This function allows you to get information about the last 20 matches for a player
#' @param api_key API key provided by RIOT games (\url{https://developer.riotgames.com/})
#' @param account_id Summoner's account id
#' @param region Summoner's region (RU, KR, BR, OCE, JP, NA... | /R/match_recent.R | no_license | jajimenezf/lolr | R | false | false | 1,297 | r | #' Summoner's recent match information
#'
#' This function allows you to get information about the last 20 matches for a player
#' @param api_key API key provided by RIOT games (\url{https://developer.riotgames.com/})
#' @param account_id Summoner's account id
#' @param region Summoner's region (RU, KR, BR, OCE, JP, NA... |
#' Coefficients of a model of class droplasso
#'
#' This function extracts the matrix of coefficients for the model(s) trained by
#' the \code{droplasso} function corresponding to regularization parameters of
#' interest.
#'
#' @param object Object of class \code{droplasso}
#' @param s Value(s) of the penalty parame... | /R/coef.droplasso.R | no_license | jpvert/droplasso | R | false | false | 962 | r | #' Coefficients of a model of class droplasso
#'
#' This function extracts the matrix of coefficients for the model(s) trained by
#' the \code{droplasso} function corresponding to regularization parameters of
#' interest.
#'
#' @param object Object of class \code{droplasso}
#' @param s Value(s) of the penalty parame... |
## Function: makeCacheMatrix
## Author: Richard vd Pol
## Date: 23-7-2015
## Desription:
## Constructor for creating a cacheMatrix object
## Parameters: a matrix object.
## Output an object with four methods:
## Set : sets the object in a different scope and clears the cache
## Get : Returns the given matrix
## SetM... | /cachematrix.R | no_license | TheDuke78/ProgrammingAssignment2 | R | false | false | 1,306 | r | ## Function: makeCacheMatrix
## Author: Richard vd Pol
## Date: 23-7-2015
## Desription:
## Constructor for creating a cacheMatrix object
## Parameters: a matrix object.
## Output an object with four methods:
## Set : sets the object in a different scope and clears the cache
## Get : Returns the given matrix
## SetM... |
library(phyloTop)
### Name: nodeImbFrac
### Title: Fraction of nodes with given imbalance
### Aliases: nodeImbFrac
### ** Examples
## Find the fraction of internal nodes with an imbalance of 5 or more,
## in a random tree with 20 tips:
tree <- rtree(20)
plot(tree)
nodeImbFrac(tree,threshold=5)
| /data/genthat_extracted_code/phyloTop/examples/nodeImbFrac.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 305 | r | library(phyloTop)
### Name: nodeImbFrac
### Title: Fraction of nodes with given imbalance
### Aliases: nodeImbFrac
### ** Examples
## Find the fraction of internal nodes with an imbalance of 5 or more,
## in a random tree with 20 tips:
tree <- rtree(20)
plot(tree)
nodeImbFrac(tree,threshold=5)
|
## load packages
library("testthat")
library("neotoma")
context("Run Neotoma examples only when not on CRAN")
test_that("Examples run without error", {
## we don't want this to run on CRAN
skip_on_cran()
## List of example topics we want to check
egs <- c('compile_downloads',
... | /neotoma/tests/testthat/test_examples.R | no_license | ingted/R-Examples | R | false | false | 1,153 | r | ## load packages
library("testthat")
library("neotoma")
context("Run Neotoma examples only when not on CRAN")
test_that("Examples run without error", {
## we don't want this to run on CRAN
skip_on_cran()
## List of example topics we want to check
egs <- c('compile_downloads',
... |
\name{simulation}
\alias{blender.reduce}
\alias{blender.shuffle}
\title{
Simulate reduced richness landscapes
}
\description{
\code{reduce} randomly selects species for inclusion in a reduced-richness
landscape based on the original. \code{shuffle} randomizes species locations
among sites.
}
\usage{
blender... | /man/simulation.Rd | no_license | davharris/blender | R | false | false | 1,212 | rd | \name{simulation}
\alias{blender.reduce}
\alias{blender.shuffle}
\title{
Simulate reduced richness landscapes
}
\description{
\code{reduce} randomly selects species for inclusion in a reduced-richness
landscape based on the original. \code{shuffle} randomizes species locations
among sites.
}
\usage{
blender... |
## The below functions will create a matrix object
## that can cache its inverse-- since matrix inversion
## is a costly computation
## makeCacheMatrix creates a special matrix object
makeCacheMatrix <- function(x = matrix()) {
inv <- NULL
set <- function(y) {
x <<- y
i... | /cachematrix.R | no_license | DataCollectingTami/ProgrammingAssignment2 | R | false | false | 995 | r | ## The below functions will create a matrix object
## that can cache its inverse-- since matrix inversion
## is a costly computation
## makeCacheMatrix creates a special matrix object
makeCacheMatrix <- function(x = matrix()) {
inv <- NULL
set <- function(y) {
x <<- y
i... |
library(httr)
library(curl)
library(jsonlite)
library(dplyr)
# start_d : 불러올 시작일 ex) 20100101
# end_d : 불러올 종료일 ex) 20100102
# start_h : 불러올 시작 시간 ex) 00
# end_h : 불러올 종료 시간 ex) 23
# location : 지점 ex) 108(서울)
# personal_key : 개인 API key
# sample url : http://data.kma.go.kr/apiData/getData?type=xml&dataCd=ASOS&dateCd=H... | /kma_time_API.R | no_license | m1109sun/Energy | R | false | false | 2,749 | r | library(httr)
library(curl)
library(jsonlite)
library(dplyr)
# start_d : 불러올 시작일 ex) 20100101
# end_d : 불러올 종료일 ex) 20100102
# start_h : 불러올 시작 시간 ex) 00
# end_h : 불러올 종료 시간 ex) 23
# location : 지점 ex) 108(서울)
# personal_key : 개인 API key
# sample url : http://data.kma.go.kr/apiData/getData?type=xml&dataCd=ASOS&dateCd=H... |
#' Ler metadados das decisões
#'
#' @param arquivos Caminhos para os htmls
#' @param diretorio Diretório onde se encontram os htmls,
#' se arquivos for NULL.
#'
#' @return tabela com metadados jurisprudenciais.
#' @export
#'
#' @examples
#' \dontrun{
#' cjsg <- tjsp_ler_cjsg()
#' }
#'
tjsp_ler_cjsg <- function(ar... | /R/tjsp_ler_cjsg.R | permissive | rebe2709/tjsp | R | false | false | 2,528 | r | #' Ler metadados das decisões
#'
#' @param arquivos Caminhos para os htmls
#' @param diretorio Diretório onde se encontram os htmls,
#' se arquivos for NULL.
#'
#' @return tabela com metadados jurisprudenciais.
#' @export
#'
#' @examples
#' \dontrun{
#' cjsg <- tjsp_ler_cjsg()
#' }
#'
tjsp_ler_cjsg <- function(ar... |
hpc <- read.csv("household_power_consumption.txt", colClasses = colclasses, na.strings=c("?"), sep=";")
hpc1 <- within(hpc, DateTime <- paste(Date, Time, sep=" "))
hpc1$DateTime = as.POSIXct(strptime(hpc1$DateTime, format = "%d/%m/%Y %H:%M:%S"))
hpc1 = subset(hpc1, DateTime >= as.POSIXct("2007-02-01") & DateTime < a... | /Plot3.R | no_license | haleemurrasheed/ExData_Plotting1 | R | false | false | 904 | r | hpc <- read.csv("household_power_consumption.txt", colClasses = colclasses, na.strings=c("?"), sep=";")
hpc1 <- within(hpc, DateTime <- paste(Date, Time, sep=" "))
hpc1$DateTime = as.POSIXct(strptime(hpc1$DateTime, format = "%d/%m/%Y %H:%M:%S"))
hpc1 = subset(hpc1, DateTime >= as.POSIXct("2007-02-01") & DateTime < a... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/resampleTensorUtilities.R
\docType{class}
\name{ResampleTensorLayer2D}
\alias{ResampleTensorLayer2D}
\title{Creates a resample tensor lambda layer (2-D)}
\value{
a resampled version of the input tensor
}
\description{
Creates a lambda layer w... | /man/ResampleTensorLayer2D.Rd | no_license | ale-tom/ANTsRNet | R | false | true | 821 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/resampleTensorUtilities.R
\docType{class}
\name{ResampleTensorLayer2D}
\alias{ResampleTensorLayer2D}
\title{Creates a resample tensor lambda layer (2-D)}
\value{
a resampled version of the input tensor
}
\description{
Creates a lambda layer w... |
require(secr)
require(scrmlebook)
require(pals)
require(plot3D)
require(sp)
tigerch = read.capthist("NagaraholeCHtimes.csv","Nagaraholetraps.csv",detector="count",noccasions=1,covnames=c("day","hour"))
cams = traps(tigerch)
quartz()
if (dim(tigerch)[2]>1) {
par(mfrow=c(3,3))
for(i in 1:dim(tigerch)[2]) plot(tigerc... | /Dorazio+Karanth tigers/Code+Data/fitNagarahole.r | no_license | david-borchers/monalisa | R | false | false | 10,315 | r | require(secr)
require(scrmlebook)
require(pals)
require(plot3D)
require(sp)
tigerch = read.capthist("NagaraholeCHtimes.csv","Nagaraholetraps.csv",detector="count",noccasions=1,covnames=c("day","hour"))
cams = traps(tigerch)
quartz()
if (dim(tigerch)[2]>1) {
par(mfrow=c(3,3))
for(i in 1:dim(tigerch)[2]) plot(tigerc... |
#' This is an internal function but need to be exported for the function ExecuteSNF.CC() call.
#'
#' This is Spectral Clustering Algorithm extracted from SNFtools package spectralClustering() with
#' a tiny modification.
#' @param affinity Similarity matrix
#' @param K Number of clusters
#' @param type The var... | /R/internal.R | no_license | buutrg/CancerSubtypes | R | false | false | 2,708 | r | #' This is an internal function but need to be exported for the function ExecuteSNF.CC() call.
#'
#' This is Spectral Clustering Algorithm extracted from SNFtools package spectralClustering() with
#' a tiny modification.
#' @param affinity Similarity matrix
#' @param K Number of clusters
#' @param type The var... |
#' Power law fitting of subtrees and their sizes by linear regression
#'
#' Fitting a tree spectrum (number of subtrees and their sizes from one tree) with power law
#' The power law fitting is done by linear regression between number of subtrees and their sizes
#' which can also be computed by \code{\link{phylogenetic... | /Misc/powerLaw.tree.R | no_license | niyongabirejunior/arteta | R | false | false | 1,462 | r | #' Power law fitting of subtrees and their sizes by linear regression
#'
#' Fitting a tree spectrum (number of subtrees and their sizes from one tree) with power law
#' The power law fitting is done by linear regression between number of subtrees and their sizes
#' which can also be computed by \code{\link{phylogenetic... |
library(devtools)
library(pkgbuild)
library(tensorflow)
# Github packages
##Seurat
devtools::install_github(repo = 'satijalab/seurat', ref= 'release/3.0')
## SingleR
devtools::install_github('dviraran/SingleR')
## r-cellassign
tensorflow::install_tensorflow()
devtools::install_github("Irrationone/cellassign") | /install_github.R | permissive | schultzelab/r_docker | R | false | false | 311 | r | library(devtools)
library(pkgbuild)
library(tensorflow)
# Github packages
##Seurat
devtools::install_github(repo = 'satijalab/seurat', ref= 'release/3.0')
## SingleR
devtools::install_github('dviraran/SingleR')
## r-cellassign
tensorflow::install_tensorflow()
devtools::install_github("Irrationone/cellassign") |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/grass7_v_info.R
\name{grass7_v_info}
\alias{grass7_v_info}
\title{QGIS algorithm v.info}
\usage{
grass7_v_info(
map = qgisprocess::qgis_default_value(),
.c = qgisprocess::qgis_default_value(),
.g = qgisprocess::qgis_default_value(),
.... | /man/grass7_v_info.Rd | permissive | VB6Hobbyst7/r_package_qgis | R | false | true | 2,320 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/grass7_v_info.R
\name{grass7_v_info}
\alias{grass7_v_info}
\title{QGIS algorithm v.info}
\usage{
grass7_v_info(
map = qgisprocess::qgis_default_value(),
.c = qgisprocess::qgis_default_value(),
.g = qgisprocess::qgis_default_value(),
.... |
#!/usr/bin/env r
library(magrittr)
library(raster)
normalize <- function(x) {
min <- raster::minValue(x)
max <- raster::maxValue(x)
return((x - min) / (max - min))
}
process_gurobi_results <- function(results, template_raster) {
result_raster <- template_raster
result_raster[] <- results$x
# Fill in the n... | /tests/process_gurobi_test_data.R | permissive | VUEG/priocomp | R | false | false | 1,871 | r | #!/usr/bin/env r
library(magrittr)
library(raster)
normalize <- function(x) {
min <- raster::minValue(x)
max <- raster::maxValue(x)
return((x - min) / (max - min))
}
process_gurobi_results <- function(results, template_raster) {
result_raster <- template_raster
result_raster[] <- results$x
# Fill in the n... |
library(randomForest);
library(caret);
library(AUC);
library(precrec);
# RF CV function
RFCV = function(train, val) {
# build model
mtry = 5;
ntree = 100;
nodesize = 20;
set.seed(1)
RF = randomForest(Severity~., data = train, mtry = mtry, ntree = ntree, replace = FALSE, nodesize = nodesize);
... | /Random Forest/RF_SMOTE.R | no_license | aammeenn/Traffic-Accident-Severity | R | false | false | 2,545 | r | library(randomForest);
library(caret);
library(AUC);
library(precrec);
# RF CV function
RFCV = function(train, val) {
# build model
mtry = 5;
ntree = 100;
nodesize = 20;
set.seed(1)
RF = randomForest(Severity~., data = train, mtry = mtry, ntree = ntree, replace = FALSE, nodesize = nodesize);
... |
library(shiny)
library(ggplot2)
# Define server logic required to draw a histogram
shinyServer(function(input, output) {
output$plots <- renderUI({
listaUI = list()
for (i in 8:length(notas)) {
listaUI = list(listaUI, h3(paste("Pregunta", names(notas)[i])),
selectInput(paste("opti... | /ejemploRenderUI.R | no_license | maorjuela73/sistabet | R | false | false | 1,976 | r | library(shiny)
library(ggplot2)
# Define server logic required to draw a histogram
shinyServer(function(input, output) {
output$plots <- renderUI({
listaUI = list()
for (i in 8:length(notas)) {
listaUI = list(listaUI, h3(paste("Pregunta", names(notas)[i])),
selectInput(paste("opti... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/point_gap.R
\name{pg_covers}
\alias{pg_covers}
\alias{pg_omits}
\title{Coverage}
\usage{
pg_covers(x, value, strict_coverage = TRUE)
pg_omits(x, value, strict_omission = FALSE)
}
\arguments{
\item{x}{a \code{pointGap} object or an object tha... | /man/pg_covers.Rd | permissive | UAB-BST-680/tblStrings | R | false | true | 1,557 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/point_gap.R
\name{pg_covers}
\alias{pg_covers}
\alias{pg_omits}
\title{Coverage}
\usage{
pg_covers(x, value, strict_coverage = TRUE)
pg_omits(x, value, strict_omission = FALSE)
}
\arguments{
\item{x}{a \code{pointGap} object or an object tha... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/many_pal.R
\name{many_pals}
\alias{many_pals}
\title{Many color palettes}
\usage{
many_pals(component = NULL, variant = NULL, theme = NULL, include_names = NULL)
}
\arguments{
\item{component}{palette's component (\code{fuel}, \code{region}).... | /man/many_pals.Rd | permissive | witch-team/witchtools | R | false | true | 524 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/many_pal.R
\name{many_pals}
\alias{many_pals}
\title{Many color palettes}
\usage{
many_pals(component = NULL, variant = NULL, theme = NULL, include_names = NULL)
}
\arguments{
\item{component}{palette's component (\code{fuel}, \code{region}).... |
rankall <- function(outcome, num = "best") {
## Read outcome data
## Check that state and outcome are valid
## For each state, find the hospital of the given rank
## Return a data frame with the hospital names and the
## (abbreviated) state name
outcome_data <- read.csv("data/outcome-of-care-mea... | /coursera/data_science/r_week4/rankall.R | no_license | akarsakov/projects | R | false | false | 1,455 | r | rankall <- function(outcome, num = "best") {
## Read outcome data
## Check that state and outcome are valid
## For each state, find the hospital of the given rank
## Return a data frame with the hospital names and the
## (abbreviated) state name
outcome_data <- read.csv("data/outcome-of-care-mea... |
library(readxl)
library(reshape2)
library(rjson)
library(RJSONIO)
###
### SICKKIDS DATA
###
raw_in = readLines("C:/Users/lauren erdman/Desktop/kidney_img/HN/SickKids/preprocessed_images_SickKids_wST_filenames_20210216.json")
library(V8)
test = v8()
test$assign("dat", JS(raw_in))
sk_list = test$get("dat")
lengt... | /0.Preprocess/prepping_skst_surg_20210216.R | no_license | martaskrt/nephronetwork | R | false | false | 21,106 | r |
library(readxl)
library(reshape2)
library(rjson)
library(RJSONIO)
###
### SICKKIDS DATA
###
raw_in = readLines("C:/Users/lauren erdman/Desktop/kidney_img/HN/SickKids/preprocessed_images_SickKids_wST_filenames_20210216.json")
library(V8)
test = v8()
test$assign("dat", JS(raw_in))
sk_list = test$get("dat")
lengt... |
#library
if(!require("Hmisc")) install.packages("Hmisc"); library("Hmisc") # load the package
if(!require("ggplot2")) install.packages("ggplot2"); library("ggplot2") # load the package
if(!require("e1071")) install.packages("e1071"); library("e1071") # load the package
if(!require("randomForest")) install.packages(... | /random_forest-with-caret.R | no_license | gauravpuri334/Business-Analytics-and-Data-Science | R | false | false | 5,831 | r | #library
if(!require("Hmisc")) install.packages("Hmisc"); library("Hmisc") # load the package
if(!require("ggplot2")) install.packages("ggplot2"); library("ggplot2") # load the package
if(!require("e1071")) install.packages("e1071"); library("e1071") # load the package
if(!require("randomForest")) install.packages(... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/package.R
\name{use_grk_starter_project}
\alias{use_grk_starter_project}
\title{Create a default project skeleton}
\usage{
use_grk_starter_project(path)
}
\arguments{
\item{path}{Path where the project will be started}
}
\description{
Uses \l... | /man/use_grk_starter_project.Rd | permissive | GerkeLab/grkmisc | R | false | true | 449 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/package.R
\name{use_grk_starter_project}
\alias{use_grk_starter_project}
\title{Create a default project skeleton}
\usage{
use_grk_starter_project(path)
}
\arguments{
\item{path}{Path where the project will be started}
}
\description{
Uses \l... |
% Generated by roxygen2 (4.1.0): do not edit by hand
% Please edit documentation in R/black_litterman.R
\name{BlackLittermanFormula}
\alias{BlackLittermanFormula}
\title{Computes the Black-Litterman formula for the moments of the posterior normal.}
\usage{
BlackLittermanFormula(Mu, Sigma, P, v, Omega)
}
\arguments{
\it... | /man/BlackLittermanFormula.Rd | no_license | arturochian/PortfolioAnalytics-1 | R | false | false | 1,084 | rd | % Generated by roxygen2 (4.1.0): do not edit by hand
% Please edit documentation in R/black_litterman.R
\name{BlackLittermanFormula}
\alias{BlackLittermanFormula}
\title{Computes the Black-Litterman formula for the moments of the posterior normal.}
\usage{
BlackLittermanFormula(Mu, Sigma, P, v, Omega)
}
\arguments{
\it... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/unpackVCF.R
\name{unpackVCF}
\alias{unpackVCF}
\title{Uncompress the .gz archives of the vcf data}
\usage{
unpackVCF(pr, year, searchDir, dir = NULL, mc.cores = 1)
}
\arguments{
\item{pr}{List or numeric list. Classically the returned object ... | /man/unpackVCF.Rd | no_license | sonthuybacha/VCF | R | false | true | 1,322 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/unpackVCF.R
\name{unpackVCF}
\alias{unpackVCF}
\title{Uncompress the .gz archives of the vcf data}
\usage{
unpackVCF(pr, year, searchDir, dir = NULL, mc.cores = 1)
}
\arguments{
\item{pr}{List or numeric list. Classically the returned object ... |
# runtime calculation
ptm <- proc.time()
# load packages and set seed
library(MASS)
library(plyr)
library(survival)
library(spcov)
library(locfdr)
set.seed(10)
## generate indicator variables to indicate which predictors will apply to
## which diseases
p <- 0.05 # insert probability here
numpre <- 100 # insert nu... | /data_sims/data_gen_sim_v2_testing_bins_rearr.r | no_license | i-pan/i2b2-HST2014 | R | false | false | 7,614 | r | # runtime calculation
ptm <- proc.time()
# load packages and set seed
library(MASS)
library(plyr)
library(survival)
library(spcov)
library(locfdr)
set.seed(10)
## generate indicator variables to indicate which predictors will apply to
## which diseases
p <- 0.05 # insert probability here
numpre <- 100 # insert nu... |
#part 3
install.packages("ggplot2")
library(ggplot2)
pm_point1999 <- filter(nei_df, year==1999, fips =="24510", type == "point")
pm_point2002 <- filter(nei_df, year==2002, fips =="24510", type == "point")
pm_point2005 <- filter(nei_df, year==2005, fips =="24510", type == "point")
pm_point2008 <- filter(nei_df, year==2... | /part3.R | no_license | silentarbitor/exdata-plotting-final | R | false | false | 2,451 | r | #part 3
install.packages("ggplot2")
library(ggplot2)
pm_point1999 <- filter(nei_df, year==1999, fips =="24510", type == "point")
pm_point2002 <- filter(nei_df, year==2002, fips =="24510", type == "point")
pm_point2005 <- filter(nei_df, year==2005, fips =="24510", type == "point")
pm_point2008 <- filter(nei_df, year==2... |
#' Convert to an HTML document
#'
#' Format for converting from R Markdown to an HTML document.
#'
#' @details
#' CSS adapted from the readtheorg theme of the org-html-themes project :
#' \url{https://github.com/fniessen/org-html-themes}, which is itself inspired by
#' the Read the docs theme : \url{https://readthedocs... | /R/readthedown.R | no_license | z-edw/rmdformats | R | false | false | 3,657 | r | #' Convert to an HTML document
#'
#' Format for converting from R Markdown to an HTML document.
#'
#' @details
#' CSS adapted from the readtheorg theme of the org-html-themes project :
#' \url{https://github.com/fniessen/org-html-themes}, which is itself inspired by
#' the Read the docs theme : \url{https://readthedocs... |
# This file reads the whole dataset ~900K and save them
# in separate files according to SurgID.
library(data.table)
library(dplyr)
# Read each dataset, select relevant columns, and finally
# combine all datasets
# 905533 in total to start with
setwd("<data file>")
dt_selected_row = NULL
for (i in 1:91){... | /code/preprocess_data.R | no_license | emily-jane-mackay/Echocardiography_STS | R | false | false | 4,520 | r | # This file reads the whole dataset ~900K and save them
# in separate files according to SurgID.
library(data.table)
library(dplyr)
# Read each dataset, select relevant columns, and finally
# combine all datasets
# 905533 in total to start with
setwd("<data file>")
dt_selected_row = NULL
for (i in 1:91){... |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do not modify this file since it was automatically generated from:
%
% discretize.R
%
% by the Rdoc compiler part of the R.oo package.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\name{addText.Discretize}
\al... | /discretizeGaussian/man/addText.Discretize.Rd | permissive | relund/discretizeNormal | R | false | false | 835 | rd | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do not modify this file since it was automatically generated from:
%
% discretize.R
%
% by the Rdoc compiler part of the R.oo package.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\name{addText.Discretize}
\al... |
#' Find missing s3 exports.
#'
#' The method is heuristic - looking for objs with a period in their name.
#'
#' @param pkg package description, can be path or package name. See
#' \code{\link{as.package}} for more information
#' @export
missing_s3 <- function(pkg = ".") {
if (!requireNamespace("roxygen2", quietly ... | /devtoolsVersion/devtools 18/R/missing-s3.r | no_license | connectthefuture/devtools-R-Forge | R | false | false | 773 | r | #' Find missing s3 exports.
#'
#' The method is heuristic - looking for objs with a period in their name.
#'
#' @param pkg package description, can be path or package name. See
#' \code{\link{as.package}} for more information
#' @export
missing_s3 <- function(pkg = ".") {
if (!requireNamespace("roxygen2", quietly ... |
# This code opens the several linear regression results produced earlier
# And combine them in a way that can be easily written to LaTeX
rm(list = ls())
library(xtable)
library(dplyr)
library(ggplot2)
library(reshape)
library(GGally)
library(MuMIn)
library(openxlsx)
setwd("~/Google Drive/EliteLaw/Generate Latex/")
#... | /Generate Latex/WriteToLatex.R | no_license | noamhabot/EliteLaw | R | false | false | 6,044 | r | # This code opens the several linear regression results produced earlier
# And combine them in a way that can be easily written to LaTeX
rm(list = ls())
library(xtable)
library(dplyr)
library(ggplot2)
library(reshape)
library(GGally)
library(MuMIn)
library(openxlsx)
setwd("~/Google Drive/EliteLaw/Generate Latex/")
#... |
# Fingerprinting worker script - running single chip enrichment option
# Delay allows time to monitor process starting up
print("preparing for script launch, 5s synch delay")
Sys.sleep(5)
# Read the genelist in
genelist <- sampleset[[13]];
total <- length(genelist)
# load contents of directory once
# this used to be ... | /Fingerprint running scripts/SCE_sq_parallel/SCE_parallel_m.R | no_license | hidelab/database-fingerprint-scripts | R | false | false | 1,110 | r | # Fingerprinting worker script - running single chip enrichment option
# Delay allows time to monitor process starting up
print("preparing for script launch, 5s synch delay")
Sys.sleep(5)
# Read the genelist in
genelist <- sampleset[[13]];
total <- length(genelist)
# load contents of directory once
# this used to be ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stocks.R
\name{splot_summary}
\alias{splot_summary}
\title{Portfolio Plots: Total Summary}
\usage{
splot_summary(p, s, save = FALSE)
}
\arguments{
\item{p}{Dataframe. Result from \code{daily_portfolio()}}
\item{s}{Dataframe. Result from \cod... | /man/splot_summary.Rd | no_license | laresbernardo/lares | R | false | true | 1,217 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stocks.R
\name{splot_summary}
\alias{splot_summary}
\title{Portfolio Plots: Total Summary}
\usage{
splot_summary(p, s, save = FALSE)
}
\arguments{
\item{p}{Dataframe. Result from \code{daily_portfolio()}}
\item{s}{Dataframe. Result from \cod... |
context("test-flow.R")
test_that("header() formatted correctly", {
skip_if_no_metaflow()
actual <- header("TestFlow")
expected <- "from metaflow import FlowSpec, step, Parameter, retry, environment, batch, catch, resources\nfrom metaflow.R import call_r\n\n\nclass TestFlow(FlowSpec):\n"
expect_equal(actual, ex... | /R/tests/testthat/test-flow.R | permissive | zhe-thoughts/metaflow | R | false | false | 2,507 | r | context("test-flow.R")
test_that("header() formatted correctly", {
skip_if_no_metaflow()
actual <- header("TestFlow")
expected <- "from metaflow import FlowSpec, step, Parameter, retry, environment, batch, catch, resources\nfrom metaflow.R import call_r\n\n\nclass TestFlow(FlowSpec):\n"
expect_equal(actual, ex... |
args <- commandArgs(trailingOnly=TRUE)
if(F) {
cat("Hello, World!
The precise 50-digits value of Pi is 3.14159265358979323846264338327950288419716939937510.
But he who would be a great man ought to regard, not himself or his interests, but what is just, whether the just act be his own or that of another. Next as to ... | /1-moderate/justify_the_text.R | no_license | OehlR/codeeval | R | false | false | 1,765 | r | args <- commandArgs(trailingOnly=TRUE)
if(F) {
cat("Hello, World!
The precise 50-digits value of Pi is 3.14159265358979323846264338327950288419716939937510.
But he who would be a great man ought to regard, not himself or his interests, but what is just, whether the just act be his own or that of another. Next as to ... |
## Coursera data science Course
## Assignment 2
## Example of how to use <<- operator,
## to assign a value to an object in an environment that is different from the current environment
## Creates a special "matrix" object that can cache its inverse
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- fu... | /cachematrix.R | no_license | AlbertoFlores95/ProgrammingAssignment2 | R | false | false | 1,165 | r | ## Coursera data science Course
## Assignment 2
## Example of how to use <<- operator,
## to assign a value to an object in an environment that is different from the current environment
## Creates a special "matrix" object that can cache its inverse
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- fu... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lba_race.R
\name{LBA-race}
\alias{LBA-race}
\alias{n1PDF}
\alias{n1CDF}
\title{LBA race functions: Likelihood for first accumulator to win.}
\usage{
n1PDF(rt, A, b, t0, ..., st0 = 0, distribution = c("norm", "gamma",
"frechet", "lnorm"), ar... | /man/LBA-race.Rd | no_license | wjhopper/rtdists | R | false | true | 6,625 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lba_race.R
\name{LBA-race}
\alias{LBA-race}
\alias{n1PDF}
\alias{n1CDF}
\title{LBA race functions: Likelihood for first accumulator to win.}
\usage{
n1PDF(rt, A, b, t0, ..., st0 = 0, distribution = c("norm", "gamma",
"frechet", "lnorm"), ar... |
# Hypothesis testing part
# t-Test
# Continuation of Week 4
# Import data and see they are OK.
dt <- read.csv("http://nb.vse.cz/~zouharj/econ/labour_market.csv")
head(dt)
# Data eyeballing.
# install.packages("GGally")
library(GGally)
ggpairs(dt) # Wait, 0s and 1s are categories, not numbers!
dt$fulltime <- factor(d... | /Lecture_5_R_Exercise.R | no_license | kangnade/R-for-Econometrics-Notes | R | false | false | 2,638 | r | # Hypothesis testing part
# t-Test
# Continuation of Week 4
# Import data and see they are OK.
dt <- read.csv("http://nb.vse.cz/~zouharj/econ/labour_market.csv")
head(dt)
# Data eyeballing.
# install.packages("GGally")
library(GGally)
ggpairs(dt) # Wait, 0s and 1s are categories, not numbers!
dt$fulltime <- factor(d... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/runDiffusionMap.R
\name{runDiffusionMap}
\alias{runDiffusionMap}
\title{Create a diffusion map from cell-level data}
\usage{
runDiffusionMap(object, ncomponents = 2, ntop = 500, feature_set = NULL,
exprs_values = "logcounts", scale_features... | /man/runDiffusionMap.Rd | permissive | chenxofhit/scater | R | false | true | 3,158 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/runDiffusionMap.R
\name{runDiffusionMap}
\alias{runDiffusionMap}
\title{Create a diffusion map from cell-level data}
\usage{
runDiffusionMap(object, ncomponents = 2, ntop = 500, feature_set = NULL,
exprs_values = "logcounts", scale_features... |
\name{bgtCI}
\alias{bgtCI}
\alias{bgtCP}
\alias{bgtBlaker}
\alias{bgtAC}
\alias{bgtWilson}
\alias{bgtWald}
\alias{bgtSOC}
\title{ Confidence Intervals for One Proportion in Binomial Group Testing }
\description{ Calculates the point estimate, the exact Clopper-Pearson and Blaker CI, the Score test deriv... | /man/bgtCI.Rd | no_license | cran/binGroup | R | false | false | 5,544 | rd | \name{bgtCI}
\alias{bgtCI}
\alias{bgtCP}
\alias{bgtBlaker}
\alias{bgtAC}
\alias{bgtWilson}
\alias{bgtWald}
\alias{bgtSOC}
\title{ Confidence Intervals for One Proportion in Binomial Group Testing }
\description{ Calculates the point estimate, the exact Clopper-Pearson and Blaker CI, the Score test deriv... |
### Figure: cost function vs. iteration ##
library(ggplot2)
dlist=c(25,30)
rlist=c(5,10)
################ plot ############
Output=read.table("Figure1.txt",header=T)
cost=c(unlist(Output[,5:19]))
iteration=rep(1:15,rep(4,15))
Setting=rep(c(sprintf("d=25,r=5 (%.2f sec/iter)",Output[1,1]),sprintf("d=25,r=10 (%.2f sec/it... | /data analysis/simulation_code/Figure1/plot_Figure1.R | no_license | Miaoyanwang/ordinal_tensor | R | false | false | 923 | r | ### Figure: cost function vs. iteration ##
library(ggplot2)
dlist=c(25,30)
rlist=c(5,10)
################ plot ############
Output=read.table("Figure1.txt",header=T)
cost=c(unlist(Output[,5:19]))
iteration=rep(1:15,rep(4,15))
Setting=rep(c(sprintf("d=25,r=5 (%.2f sec/iter)",Output[1,1]),sprintf("d=25,r=10 (%.2f sec/it... |
#(資料合併)-----
#library(readxl)
#sheet1 <- read_excel("/Users/hazel_lin/Documents/Lin Yi-Sin/地政所/1092/四234_電腦輔助大量估價專題研究/data/桃園.xlsx", sheet = "不動產買賣_381214")
#sheet2 <- read_excel("/Users/hazel_lin/Documents/Lin Yi-Sin/地政所/1092/四234_電腦輔助大量估價專題研究/data/桃園.xlsx", sheet = "不動產買賣_350000")
#sheet3 <- read_excel("/Users/hazel_... | /data.R | no_license | hazel-ys-lin/mass-appraisal-data-tidyup | R | false | false | 15,367 | r | #(資料合併)-----
#library(readxl)
#sheet1 <- read_excel("/Users/hazel_lin/Documents/Lin Yi-Sin/地政所/1092/四234_電腦輔助大量估價專題研究/data/桃園.xlsx", sheet = "不動產買賣_381214")
#sheet2 <- read_excel("/Users/hazel_lin/Documents/Lin Yi-Sin/地政所/1092/四234_電腦輔助大量估價專題研究/data/桃園.xlsx", sheet = "不動產買賣_350000")
#sheet3 <- read_excel("/Users/hazel_... |
library(shiny)
library(dplyr)
library(readxl)
# Prepare raw data to extract input variables
mydata <- read_xlsx("raw_data.xlsx")
colnames(mydata) <- c("manager", "region", "city", "item", "dos", "customer",
"s_volume", "sales", "cost", "income")
managers <- as.factor(unique(mydata$manager))
reg... | /sales_app_kt/ui.R | no_license | makarovvadari/sales_app_kt | R | false | false | 739 | r | library(shiny)
library(dplyr)
library(readxl)
# Prepare raw data to extract input variables
mydata <- read_xlsx("raw_data.xlsx")
colnames(mydata) <- c("manager", "region", "city", "item", "dos", "customer",
"s_volume", "sales", "cost", "income")
managers <- as.factor(unique(mydata$manager))
reg... |
setClass("DMA", representation(model = "list", data = "list", Est = "list"))
setMethod("show", "DMA", function(object) {
iK = ncol(object@data$mF)
iT = nrow(object@data$mF)
iM = object@Est$iM
vDelta = object@model$vDelta
iD = length(vDelta)
dBeta = object@model$dBeta
dAlpha = object@model$dAlp... | /eDMA/R/ClassMethods.R | no_license | akhikolla/TestedPackages-NoIssues | R | false | false | 13,369 | r | setClass("DMA", representation(model = "list", data = "list", Est = "list"))
setMethod("show", "DMA", function(object) {
iK = ncol(object@data$mF)
iT = nrow(object@data$mF)
iM = object@Est$iM
vDelta = object@model$vDelta
iD = length(vDelta)
dBeta = object@model$dBeta
dAlpha = object@model$dAlp... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.