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 |
|---|---|---|---|---|---|---|---|---|---|
# Load libraries
library(ggplot2)
library(Seurat)
library(dplyr)
library(Matrix)
library(scales)
library(cowplot)
library(gplots)
library(GSA)
library(stringr)
library(DropletUtils)
library(devtools)
library(plyr)
# read csv file
EGFPcounts <- read.csv(file = "../data/EF_293T_3T3_mixing_analysis.csv")
EGFPcounts$Ty... | /species_mix/code/02_mixing_plots-other.R | no_license | evgenijfiskin/phage-atac | R | false | false | 2,701 | r | # Load libraries
library(ggplot2)
library(Seurat)
library(dplyr)
library(Matrix)
library(scales)
library(cowplot)
library(gplots)
library(GSA)
library(stringr)
library(DropletUtils)
library(devtools)
library(plyr)
# read csv file
EGFPcounts <- read.csv(file = "../data/EF_293T_3T3_mixing_analysis.csv")
EGFPcounts$Ty... |
#' Automatically load data and packages for a project.
#'
#' This function automatically load all of the data and packages used by
#' the project from which it is called. The behaviour can be controlled by
#' adjusting the \code{\link{project.config}} configuration.
#'
#' @param override.config Named list, allows over... | /R/load.project.R | no_license | pomalley08/ProjectTemplate | R | false | false | 8,776 | r | #' Automatically load data and packages for a project.
#'
#' This function automatically load all of the data and packages used by
#' the project from which it is called. The behaviour can be controlled by
#' adjusting the \code{\link{project.config}} configuration.
#'
#' @param override.config Named list, allows over... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/visualization_functions.R
\name{plot_umaps_w_counts}
\alias{plot_umaps_w_counts}
\title{plot_umaps_w_counts}
\usage{
plot_umaps_w_counts(sce, genes, size = 0.25, ncol = NULL)
}
\arguments{
\item{sce}{SingleCellExperiment object containing gen... | /man/plot_umaps_w_counts.Rd | permissive | MarioniLab/geneBasisR | R | false | true | 755 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/visualization_functions.R
\name{plot_umaps_w_counts}
\alias{plot_umaps_w_counts}
\title{plot_umaps_w_counts}
\usage{
plot_umaps_w_counts(sce, genes, size = 0.25, ncol = NULL)
}
\arguments{
\item{sce}{SingleCellExperiment object containing gen... |
library(shiny)
library(dplyr)
library(shinydashboard)
#library(policyPlot)
library(plotly)
ui <- dashboardPage(
dashboardHeader(title = "Basic dashboard",
dropdownMenuOutput("messageMenu")
),
#dashboardSidebar(),
## Sidebar content
dashboardSidebar(
sidebarMenu(
id = "tabs",
... | /gtrendsApp/ui.R | no_license | lmnathe/LucasNathe | R | false | false | 1,538 | r | library(shiny)
library(dplyr)
library(shinydashboard)
#library(policyPlot)
library(plotly)
ui <- dashboardPage(
dashboardHeader(title = "Basic dashboard",
dropdownMenuOutput("messageMenu")
),
#dashboardSidebar(),
## Sidebar content
dashboardSidebar(
sidebarMenu(
id = "tabs",
... |
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/as.regexr.R
\name{as.regexr.default}
\alias{as.regexr.default}
\title{Coerce default to regexr}
\usage{
\method{as.regexr}{default}(x, names = TRUE, comments = TRUE,
names.above = FALSE, comments.below = FALSE, ...)
}
\argu... | /man/as.regexr.default.Rd | no_license | cran/regexr | R | false | false | 1,091 | rd | % Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/as.regexr.R
\name{as.regexr.default}
\alias{as.regexr.default}
\title{Coerce default to regexr}
\usage{
\method{as.regexr}{default}(x, names = TRUE, comments = TRUE,
names.above = FALSE, comments.below = FALSE, ...)
}
\argu... |
# Lapse Report generator
# Jadon Thomson
# 2017-02-03
#
# Initialize
#
rm(list = ls())
gc()
Path <- getwd()
source(paste0(Path,"/R/Installer.R"))
# Set end date (generally leave 5 months gap)
DateEnd <- as.Date("2016/09/30")
# Begin Date, if blank will take from the beginning of the book
DateStart <- as.Date("2... | /main.r | no_license | ZestLife/Agent-Lapse-Reporting | R | false | false | 779 | r | # Lapse Report generator
# Jadon Thomson
# 2017-02-03
#
# Initialize
#
rm(list = ls())
gc()
Path <- getwd()
source(paste0(Path,"/R/Installer.R"))
# Set end date (generally leave 5 months gap)
DateEnd <- as.Date("2016/09/30")
# Begin Date, if blank will take from the beginning of the book
DateStart <- as.Date("2... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cvForecastExtraFunctions.R
\name{fc_auto.arima}
\alias{fc_auto.arima}
\title{auto.arima forecast wrapper}
\usage{
fc_auto.arima(x, h, level = 95, onlyfc = TRUE, xreg = NULL,
newxreg = NULL, ...)
}
\arguments{
\item{x}{'ts' data}
\item{h}{f... | /man/fc_auto.arima.Rd | permissive | evandeilton/cvforecast | R | false | true | 905 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cvForecastExtraFunctions.R
\name{fc_auto.arima}
\alias{fc_auto.arima}
\title{auto.arima forecast wrapper}
\usage{
fc_auto.arima(x, h, level = 95, onlyfc = TRUE, xreg = NULL,
newxreg = NULL, ...)
}
\arguments{
\item{x}{'ts' data}
\item{h}{f... |
# TGIR-COBRE Proposal Analysis
#### Variables of Interest ####
# COVID Risk Behaviors:
# socialExposureIndex <- scale(scale(d$socialPeople) + scale(d$socialFreq) + d$barsW + d$visitFriendsHouseW +
# d$hostVisitorsW + d$party10W + d$party50W + d$indoorDiningW + d$indoorGymW)
# riskReduci... | /r/analysis_TGIR_COBRE.R | permissive | tshrum/AltruismEnvironmentalismCOVIDBehavior | R | false | false | 10,549 | r | # TGIR-COBRE Proposal Analysis
#### Variables of Interest ####
# COVID Risk Behaviors:
# socialExposureIndex <- scale(scale(d$socialPeople) + scale(d$socialFreq) + d$barsW + d$visitFriendsHouseW +
# d$hostVisitorsW + d$party10W + d$party50W + d$indoorDiningW + d$indoorGymW)
# riskReduci... |
library(shiny)
library(reactable)
library(readxl)
library(tidyverse)
library(shinythemes)
codebook = read_excel('SIGMA_DataDictionary_public.xlsx')
codebook = codebook %>%
select(1, 3, 4, 8, 9, 13)
ui <- fluidPage(theme = shinytheme("sandstone"),
tabsetPanel(
... | /old/app_v_0_3.R | no_license | benjsimsa/SIGMA-Interactive-Codebook | R | false | false | 6,993 | r | library(shiny)
library(reactable)
library(readxl)
library(tidyverse)
library(shinythemes)
codebook = read_excel('SIGMA_DataDictionary_public.xlsx')
codebook = codebook %>%
select(1, 3, 4, 8, 9, 13)
ui <- fluidPage(theme = shinytheme("sandstone"),
tabsetPanel(
... |
# College Football Data API
#
# This is an API for accessing all sorts of college football data. It currently has a wide array of data ranging from play by play to player statistics to game scores and more.
#
# OpenAPI spec version: 2.3.5
# Contact: admin@collegefootballdata.com
# Generated by: https://github.com/swag... | /R/RatingsApi.r | no_license | saiemgilani/cfbd-api-R | R | false | false | 4,887 | r | # College Football Data API
#
# This is an API for accessing all sorts of college football data. It currently has a wide array of data ranging from play by play to player statistics to game scores and more.
#
# OpenAPI spec version: 2.3.5
# Contact: admin@collegefootballdata.com
# Generated by: https://github.com/swag... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/spectralNMF.R
\name{nonNegativePreprocessing}
\alias{nonNegativePreprocessing}
\title{condition datamatrix to input in and condition properly for NMF}
\usage{
nonNegativePreprocessing(spectra, method = "")
}
\arguments{
\item{spectra}{matrix ... | /man/nonNegativePreprocessing.Rd | no_license | cran/spectralAnalysis | R | false | true | 652 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/spectralNMF.R
\name{nonNegativePreprocessing}
\alias{nonNegativePreprocessing}
\title{condition datamatrix to input in and condition properly for NMF}
\usage{
nonNegativePreprocessing(spectra, method = "")
}
\arguments{
\item{spectra}{matrix ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/options.R
\name{Ryacas_options}
\alias{Ryacas_options}
\title{Set or get options for the Ryacas package}
\usage{
Ryacas_options(...)
}
\arguments{
\item{...}{Option names to retrieve option values or \verb{[key] = [value]} pairs to set option... | /fuzzedpackages/Ryacas0/man/Ryacas_options.Rd | no_license | akhikolla/testpackages | R | false | true | 709 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/options.R
\name{Ryacas_options}
\alias{Ryacas_options}
\title{Set or get options for the Ryacas package}
\usage{
Ryacas_options(...)
}
\arguments{
\item{...}{Option names to retrieve option values or \verb{[key] = [value]} pairs to set option... |
#' Multivariate interpolation
#'
#' This package provides a multivariate extension of the interpolation techniques presented in the paper by Shepard (1968).
#'
#' The main function to prform multivariate interpolation using the package \pkg{mvInterpolate} is \code{\link{wintpl}}.
#'
#' @author Andreas Mändle, \email{ma... | /R/shepard.R | no_license | amaendle/mvInterpolation | R | false | false | 14,213 | r | #' Multivariate interpolation
#'
#' This package provides a multivariate extension of the interpolation techniques presented in the paper by Shepard (1968).
#'
#' The main function to prform multivariate interpolation using the package \pkg{mvInterpolate} is \code{\link{wintpl}}.
#'
#' @author Andreas Mändle, \email{ma... |
## Put comments here that give an overall description of what your
## functions do
## Makes a new matrix that contains the function set, get, setinverse and getinverse
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
... | /cachematrix.R | no_license | RomiGoldner/ProgrammingAssignment2 | R | false | false | 867 | r | ## Put comments here that give an overall description of what your
## functions do
## Makes a new matrix that contains the function set, get, setinverse and getinverse
makeCacheMatrix <- function(x = matrix()) {
m <- NULL
set <- function(y) {
x <<- y
m <<- NULL
}
get <- function() x
... |
##############################################
######## Distance Between two lists ##########
##############################################
dist.list <- function(key1, lat1, long1, key2, lat2, long2, maxdist){
#convert all coordinates to be numeric
coor <- c(lat1, long1, lat2, long2)
for(i in 1:4){
coor[i] <-... | /DistListFunction.R | no_license | wward9/GIS-Analysis-Script | R | false | false | 1,043 | r | ##############################################
######## Distance Between two lists ##########
##############################################
dist.list <- function(key1, lat1, long1, key2, lat2, long2, maxdist){
#convert all coordinates to be numeric
coor <- c(lat1, long1, lat2, long2)
for(i in 1:4){
coor[i] <-... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/hello.R
\name{sum_f}
\alias{sum_f}
\title{Adds two numbers}
\usage{
sum_f(x, y)
}
\arguments{
\item{x}{A number}
\item{y}{A number}
}
\value{
The sum of \code{x} and \code{y}
}
\description{
The function returns the sum of two numbers
}
\exam... | /man/sum_f.Rd | permissive | Pradeepprabhakar92/DATA-598-WI20-week-7 | R | false | true | 339 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/hello.R
\name{sum_f}
\alias{sum_f}
\title{Adds two numbers}
\usage{
sum_f(x, y)
}
\arguments{
\item{x}{A number}
\item{y}{A number}
}
\value{
The sum of \code{x} and \code{y}
}
\description{
The function returns the sum of two numbers
}
\exam... |
## append_ex: example of appending newly processed data to compiled/batch
## data file.
## Author: Michaela A. Kratofil, Cascadia Research
## Updated: 16 Feb 2021
## ========================================================================== ##
## load packages
library(dplyr)
library(lubridate)
## read i... | /append_ex.R | no_license | makratofil/crc-hawaii-tags | R | false | false | 1,544 | r | ## append_ex: example of appending newly processed data to compiled/batch
## data file.
## Author: Michaela A. Kratofil, Cascadia Research
## Updated: 16 Feb 2021
## ========================================================================== ##
## load packages
library(dplyr)
library(lubridate)
## read i... |
findInitialDay <- function(state){
confirmed_cases <- global_confirmed_cases %>%
select(-`Province/State`, -Lat, -Long) %>%
group_by(`Country/Region`) %>%
filter(`Country/Region` == state) %>%
summarise_all(list(total = sum))
confirmed_deaths <- global_confirmed_deaths %>%
select(-`Province... | /R/Ad_hoc_computations/detrmine_starting_day.R | permissive | nitayalon/COVID-19 | R | false | false | 2,087 | r | findInitialDay <- function(state){
confirmed_cases <- global_confirmed_cases %>%
select(-`Province/State`, -Lat, -Long) %>%
group_by(`Country/Region`) %>%
filter(`Country/Region` == state) %>%
summarise_all(list(total = sum))
confirmed_deaths <- global_confirmed_deaths %>%
select(-`Province... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tidygraph-package.R
\docType{package}
\name{tidygraph-package}
\alias{tidygraph}
\alias{tidygraph-package}
\title{tidygraph: A Tidy API for Graph Manipulation}
\description{
\if{html}{\figure{logo.png}{options: align='right'}}
A graph, while... | /man/tidygraph-package.Rd | no_license | gravitytrope/tidygraph | R | false | true | 892 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tidygraph-package.R
\docType{package}
\name{tidygraph-package}
\alias{tidygraph}
\alias{tidygraph-package}
\title{tidygraph: A Tidy API for Graph Manipulation}
\description{
\if{html}{\figure{logo.png}{options: align='right'}}
A graph, while... |
# Exploratory Data Analysis
# course project
# plot4
rm(list=ls())
#reading data into R:
data<- read.table("household_power_consumption.txt", sep=";",nrows= 2075260, header=TRUE, quote= "", strip.white=TRUE, stringsAsFactors = FALSE, na.strings= "?")
# Subsetting the full data to required date:
sub<- subset(data, ... | /plot4.R | no_license | mahipal08/ExData_Plotting1 | R | false | false | 1,504 | r | # Exploratory Data Analysis
# course project
# plot4
rm(list=ls())
#reading data into R:
data<- read.table("household_power_consumption.txt", sep=";",nrows= 2075260, header=TRUE, quote= "", strip.white=TRUE, stringsAsFactors = FALSE, na.strings= "?")
# Subsetting the full data to required date:
sub<- subset(data, ... |
library(here)
library(DBI)
library(RSQLite)
library(tidyverse)
library(magrittr)
| /R/libraries.R | no_license | floattheboat/baseball-analyses | R | false | false | 88 | r |
library(here)
library(DBI)
library(RSQLite)
library(tidyverse)
library(magrittr)
|
#' Modify table_header
#'
#' This is a function meant for advanced users to gain
#' more control over the characteristics of the resulting
#' gtsummary table.
#'
#' Review the
#' \href{http://www.danieldsjoberg.com/gtsummary/articles/gtsummary_definition.html}{gtsummary definition}
#' vignette for information on `.$tab... | /R/modify_table_header.R | permissive | veseshan/gtsummary | R | false | false | 7,437 | r | #' Modify table_header
#'
#' This is a function meant for advanced users to gain
#' more control over the characteristics of the resulting
#' gtsummary table.
#'
#' Review the
#' \href{http://www.danieldsjoberg.com/gtsummary/articles/gtsummary_definition.html}{gtsummary definition}
#' vignette for information on `.$tab... |
# Estatistica: Teoria e Prática - Seção 13, aula 20
#
trees
InsectSprays
hist(trees$Height, main="Árvores", ylab="Frequência", xlab="Altura", col="blue")
densidade = density(trees$Height)
plot(densidade)
plot(trees$Girth, trees$Volume, main="Árvores", col="red", pch=20)
boxplot(trees$Volume, main="Árvores", col = ... | /Udemy/Estatistica Teoria e Pratica/Estatistica_Teoria_e_Pratica-s1320.R | permissive | tarsoqueiroz/Rlang | R | false | false | 1,498 | r | # Estatistica: Teoria e Prática - Seção 13, aula 20
#
trees
InsectSprays
hist(trees$Height, main="Árvores", ylab="Frequência", xlab="Altura", col="blue")
densidade = density(trees$Height)
plot(densidade)
plot(trees$Girth, trees$Volume, main="Árvores", col="red", pch=20)
boxplot(trees$Volume, main="Árvores", col = ... |
\name{pctree}
\alias{pctree}
\alias{plot.pctree}
\alias{print.pctree}
\alias{predict.pctree}
\alias{itempar.pctree}
\alias{threshpar.pctree}
\title{Partial Credit Trees}
\description{
Recursive partitioning (also known as trees) based on partial credit models.
}
\usage{
pctree(formula, data, na.action, nullcats =... | /man/pctree.Rd | no_license | cran/psychotree | R | false | false | 5,204 | rd | \name{pctree}
\alias{pctree}
\alias{plot.pctree}
\alias{print.pctree}
\alias{predict.pctree}
\alias{itempar.pctree}
\alias{threshpar.pctree}
\title{Partial Credit Trees}
\description{
Recursive partitioning (also known as trees) based on partial credit models.
}
\usage{
pctree(formula, data, na.action, nullcats =... |
#' Load test data for the metabric re-evaluation with METABRIC 1
#'
#' Loads data for gene expression, copy number, clinical covariates and clinical survival times for the test dataset
#' used to evlauate model scores.
#'
#' @param loadSurvData specifies if survival data is loaded. Should be set to false to users who d... | /loadFederationMetabricTestData1.R | no_license | Sage-Bionetworks/Federation | R | false | false | 1,419 | r | #' Load test data for the metabric re-evaluation with METABRIC 1
#'
#' Loads data for gene expression, copy number, clinical covariates and clinical survival times for the test dataset
#' used to evlauate model scores.
#'
#' @param loadSurvData specifies if survival data is loaded. Should be set to false to users who d... |
############ Third Plot ############
Data2$Sub_metering_1 <- as.numeric(as.character(Data2$Sub_metering_1))
Data2$Sub_metering_2 <- as.numeric(as.character(Data2$Sub_metering_2))
Data2$Sub_metering_3 <- as.numeric(as.character(Data2$Sub_metering_3))
with(Data2,plot(DateTime,Sub_metering_1,type = "l",xlab = "",yla... | /plot3.R | no_license | jerony/ExData_Plotting1 | R | false | false | 982 | r | ############ Third Plot ############
Data2$Sub_metering_1 <- as.numeric(as.character(Data2$Sub_metering_1))
Data2$Sub_metering_2 <- as.numeric(as.character(Data2$Sub_metering_2))
Data2$Sub_metering_3 <- as.numeric(as.character(Data2$Sub_metering_3))
with(Data2,plot(DateTime,Sub_metering_1,type = "l",xlab = "",yla... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{encourage}
\alias{encourage}
\title{encourages}
\usage{
encourage()
}
\description{
encourages
}
\note{
adapted from https://github.com/r-lib/testthat
}
| /man/encourage.Rd | no_license | mpio-be/DataEntry | R | false | true | 245 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{encourage}
\alias{encourage}
\title{encourages}
\usage{
encourage()
}
\description{
encourages
}
\note{
adapted from https://github.com/r-lib/testthat
}
|
library(ggplot2)
library(zoo)
library(dplyr)
library(xtable)
library(RCurl)
library(timeDate)
library(devtools)
library(bigrquery)
library(ggmap)
library(stringr)
# reading data from previously obtained google bigquery, Bike_Data_Pull.R
bike_stations <- readRDS("C:/Users/Tyler/Desktop/MSPA/MSPA 498/bike_st... | /Bike_Modeling.R | no_license | SPCRLYST/BikeProject | R | false | false | 11,187 | r | library(ggplot2)
library(zoo)
library(dplyr)
library(xtable)
library(RCurl)
library(timeDate)
library(devtools)
library(bigrquery)
library(ggmap)
library(stringr)
# reading data from previously obtained google bigquery, Bike_Data_Pull.R
bike_stations <- readRDS("C:/Users/Tyler/Desktop/MSPA/MSPA 498/bike_st... |
#' @title Finding gene homologs
#' @description
#' This function returns a dataframe with homolog IDs and NA row for the genes with no homologs.
#' @details
#' This function takes a vector of IDs. If the IDs are not ENTREZ IDs,
#' they are converted to the ENTREZ ID format. Next, the homologs of the IDs are found using... | /R/translate.R | permissive | Troshchk/bioEAT | R | false | false | 4,385 | r | #' @title Finding gene homologs
#' @description
#' This function returns a dataframe with homolog IDs and NA row for the genes with no homologs.
#' @details
#' This function takes a vector of IDs. If the IDs are not ENTREZ IDs,
#' they are converted to the ENTREZ ID format. Next, the homologs of the IDs are found using... |
# Summarize the parameters in a table
# load pkgs -----
library(r4ss)
library(dplyr)
# Read in the ctl -----
# note that both CAPAM_platoons_template_current and
# CAPAM_platoon_template_initF were used, but the only differences between the
# ctl file are the CV for the platoons, and the use of init F params in the in... | /code/5_params_table.R | no_license | iantaylor-NOAA/CAPAM_platoons_SS | R | false | false | 2,929 | r | # Summarize the parameters in a table
# load pkgs -----
library(r4ss)
library(dplyr)
# Read in the ctl -----
# note that both CAPAM_platoons_template_current and
# CAPAM_platoon_template_initF were used, but the only differences between the
# ctl file are the CV for the platoons, and the use of init F params in the in... |
# 1. save in R ------------------------------------------------------------
# 2. commit ---------------------------------------------------------------
# 3. write some stuff --------------------------------------------------------
# 4. wait the left things dispear, then upload ----------------------------
| /how to use git.R | no_license | 2020711mimi/test2 | R | false | false | 316 | r |
# 1. save in R ------------------------------------------------------------
# 2. commit ---------------------------------------------------------------
# 3. write some stuff --------------------------------------------------------
# 4. wait the left things dispear, then upload ----------------------------
|
#
# This file is part of the CNO software
#
# Copyright (c) 2011-2013 - EBI
#
# File author(s): CNO developers (cno-dev@ebi.ac.uk)
#
# Distributed under the GPLv3 License.
# See accompanying file LICENSE.txt or copy at
# http://www.gnu.org/licenses/gpl-3.0.html
#
# CNO website: http://www.cellnopt.org
#
####... | /R/model2igraph.R | no_license | saezlab/CellNOptR | R | false | false | 735 | r | #
# This file is part of the CNO software
#
# Copyright (c) 2011-2013 - EBI
#
# File author(s): CNO developers (cno-dev@ebi.ac.uk)
#
# Distributed under the GPLv3 License.
# See accompanying file LICENSE.txt or copy at
# http://www.gnu.org/licenses/gpl-3.0.html
#
# CNO website: http://www.cellnopt.org
#
####... |
library(EvCombR)
### Name: yComb
### Title: Yager's Combination Operator
### Aliases: yComb
### ** Examples
# state space
stateSpace <- c("a", "b", "c")
# mass functions
m1 <- mass(list("a"=0.1, "a/b/c"=0.9), stateSpace)
m2 <- mass(list("b"=0.2, "a/b/c"=0.8), stateSpace)
# Yager's combination
yComb(m1, m2)
# or ... | /data/genthat_extracted_code/EvCombR/examples/yComb.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 346 | r | library(EvCombR)
### Name: yComb
### Title: Yager's Combination Operator
### Aliases: yComb
### ** Examples
# state space
stateSpace <- c("a", "b", "c")
# mass functions
m1 <- mass(list("a"=0.1, "a/b/c"=0.9), stateSpace)
m2 <- mass(list("b"=0.2, "a/b/c"=0.8), stateSpace)
# Yager's combination
yComb(m1, m2)
# or ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mghheader.R
\name{mghheader.vox2ras.tkreg}
\alias{mghheader.vox2ras.tkreg}
\title{Compute vox2ras-tkreg matrix from basic MGH header fields.}
\usage{
mghheader.vox2ras.tkreg(header)
}
\arguments{
\item{header}{the MGH header}
}
\value{
4x4 nu... | /man/mghheader.vox2ras.tkreg.Rd | permissive | dfsp-spirit/freesurferformats | R | false | true | 1,338 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/mghheader.R
\name{mghheader.vox2ras.tkreg}
\alias{mghheader.vox2ras.tkreg}
\title{Compute vox2ras-tkreg matrix from basic MGH header fields.}
\usage{
mghheader.vox2ras.tkreg(header)
}
\arguments{
\item{header}{the MGH header}
}
\value{
4x4 nu... |
##################
# CCES Analysis ##
##################
setwd("C:/Users/wooki/Dropbox/tapsDisasters")
ccesdisaster <- read.csv("data/cces_panel/ccesdisaster_longformat.csv")
ccesdisaster <- read.csv("C:/Users/wooki/Desktop/cces_final.csv")# - done
ccesdisaster <- ccesdisaster[,-c(1,2)]
names(ccesdisaster)
# ... | /forpaper.R | no_license | HungryLim/Natural-disaster-president-and-voters | R | false | false | 8,697 | r | ##################
# CCES Analysis ##
##################
setwd("C:/Users/wooki/Dropbox/tapsDisasters")
ccesdisaster <- read.csv("data/cces_panel/ccesdisaster_longformat.csv")
ccesdisaster <- read.csv("C:/Users/wooki/Desktop/cces_final.csv")# - done
ccesdisaster <- ccesdisaster[,-c(1,2)]
names(ccesdisaster)
# ... |
library(colorspace)
library(seriation)
library(MASS)
bank=read.table("bank.csv",header=TRUE,sep=";")
yesBank=bank[bank$y=='yes',]
noBank=bank[bank$y=='no',]
#show the individual attribution in bar
# age for y == yes and y == no
#barplot(table(yesBank$age),main="age of the clients who subscribed",xlab="age",ylab="numb... | /R/lab1/basic.R | no_license | AtwoodDeng/homework2014 | R | false | false | 4,947 | r | library(colorspace)
library(seriation)
library(MASS)
bank=read.table("bank.csv",header=TRUE,sep=";")
yesBank=bank[bank$y=='yes',]
noBank=bank[bank$y=='no',]
#show the individual attribution in bar
# age for y == yes and y == no
#barplot(table(yesBank$age),main="age of the clients who subscribed",xlab="age",ylab="numb... |
# Loading the necessary Libraries
library(RSQLite)
# Downloading file if it does not exist
file_name <- "exdata%2Fdata%2Fhousehold_power_consumption.zip"
if(!file.exists(file_name)) {
url <- "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(url, destfile = file_n... | /plot4.R | no_license | fash33/ExData_Plotting1 | R | false | false | 1,823 | r | # Loading the necessary Libraries
library(RSQLite)
# Downloading file if it does not exist
file_name <- "exdata%2Fdata%2Fhousehold_power_consumption.zip"
if(!file.exists(file_name)) {
url <- "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2Fhousehold_power_consumption.zip"
download.file(url, destfile = file_n... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/waf_operations.R
\name{waf_get_size_constraint_set}
\alias{waf_get_size_constraint_set}
\title{Returns the SizeConstraintSet specified by SizeConstraintSetId}
\usage{
waf_get_size_constraint_set(SizeConstraintSetId)
}
\arguments{
\item{SizeCo... | /paws/man/waf_get_size_constraint_set.Rd | permissive | ryanb8/paws | R | false | true | 993 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/waf_operations.R
\name{waf_get_size_constraint_set}
\alias{waf_get_size_constraint_set}
\title{Returns the SizeConstraintSet specified by SizeConstraintSetId}
\usage{
waf_get_size_constraint_set(SizeConstraintSetId)
}
\arguments{
\item{SizeCo... |
#' Extract information from fitted models
#'
#' [extract3logit()] extracts all information which is relevant for
#' computing the vector field(s) from the object passed to argument `x`. See
#' **Details** for information on how new `S3` methods of generic
#' [extract3logit()] should be implemented.
#'
#' When a speci... | /R/extract3logit.R | no_license | f-santi/plot3logit | R | false | false | 9,933 | r |
#' Extract information from fitted models
#'
#' [extract3logit()] extracts all information which is relevant for
#' computing the vector field(s) from the object passed to argument `x`. See
#' **Details** for information on how new `S3` methods of generic
#' [extract3logit()] should be implemented.
#'
#' When a speci... |
# prufu umhverfi fyrir gagnvirknina, prófa hér þætti forritsins
manuds = vector(mode="list", length=13)
names(manuds) = c(month.name,"Year")
for(i in 1:13)
{
manuds[[i]] = i;
}
vedurs = vector(mode="list", length=6);
names(vedurs) = c("High", "Low", "Days", "mm", "Hours", "Daylight");
for(j in 1:length(vedurs))
{
... | /gagnvirknitest/server.R | no_license | Valdegg/travelplanner | R | false | false | 3,295 | r | # prufu umhverfi fyrir gagnvirknina, prófa hér þætti forritsins
manuds = vector(mode="list", length=13)
names(manuds) = c(month.name,"Year")
for(i in 1:13)
{
manuds[[i]] = i;
}
vedurs = vector(mode="list", length=6);
names(vedurs) = c("High", "Low", "Days", "mm", "Hours", "Daylight");
for(j in 1:length(vedurs))
{
... |
## Download data
# training data : https://www.kaggle.com/c/titanic/download/train.csv
# testing data : https://www.kaggle.com/c/titanic/download/test.csv
url_train <- "https://www.kaggle.com/c/titanic/download/train.csv"
url_test <- "https://www.kaggle.com/c/titanic/download/test.csv"
download.file(url_train, dest... | /t-download.R | no_license | NikhilsCodeHub/Titanic_Prediction_Model | R | false | false | 422 | r | ## Download data
# training data : https://www.kaggle.com/c/titanic/download/train.csv
# testing data : https://www.kaggle.com/c/titanic/download/test.csv
url_train <- "https://www.kaggle.com/c/titanic/download/train.csv"
url_test <- "https://www.kaggle.com/c/titanic/download/test.csv"
download.file(url_train, dest... |
# Code for creating probability plots in R
# It is stored in the file
#
# microwave.R
#
# Any line preceded with a pound sign is a
# comment that is ignored by the program.
# Data are read into a data frame from the file
#
# microwave.closed.dat
mdat <- read.table... | /STAT 501 - Multivariate Statistics/Homework/HW4/microwave.R | no_license | stharms/assignments | R | false | false | 1,582 | r |
# Code for creating probability plots in R
# It is stored in the file
#
# microwave.R
#
# Any line preceded with a pound sign is a
# comment that is ignored by the program.
# Data are read into a data frame from the file
#
# microwave.closed.dat
mdat <- read.table... |
library(pixmap)
library(bmp)
r=read.bmp('AnnaKarina.bmp')
pr=pixmapGrey(r)
plot(pr)
| /Poster.R | no_license | roland-id-au/UQ-STAT1201-Poster | R | false | false | 84 | r | library(pixmap)
library(bmp)
r=read.bmp('AnnaKarina.bmp')
pr=pixmapGrey(r)
plot(pr)
|
############ Default parameters ############
ctr=list(lambda1=1000, lambda2=1000,muy=1, stepsize="fixed",lx="1d",ly="1d",
L = 1, use.gram = TRUE, maxiter = 2000, tol = 1e-5, init = NULL, sigma = 0.9)
c1=list(n=200,n_test=100,px=40,py=20,noise.signal=0.5,noise.response=sqrt(5),dataseed=1,typeb="onebump",typ... | /msnet_simu_fun2.R | no_license | liyi-1989/msnet | R | false | false | 1,425 | r | ############ Default parameters ############
ctr=list(lambda1=1000, lambda2=1000,muy=1, stepsize="fixed",lx="1d",ly="1d",
L = 1, use.gram = TRUE, maxiter = 2000, tol = 1e-5, init = NULL, sigma = 0.9)
c1=list(n=200,n_test=100,px=40,py=20,noise.signal=0.5,noise.response=sqrt(5),dataseed=1,typeb="onebump",typ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/m2b.R
\docType{package}
\name{m2b}
\alias{m2b}
\alias{m2b-package}
\title{Movement to behaviour package}
\description{
A package to infer behaviour and social interaction from
movement data
}
\details{
Animal behaviour, including social inter... | /man/m2b.Rd | no_license | ldbk/m2b | R | false | true | 2,154 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/m2b.R
\docType{package}
\name{m2b}
\alias{m2b}
\alias{m2b-package}
\title{Movement to behaviour package}
\description{
A package to infer behaviour and social interaction from
movement data
}
\details{
Animal behaviour, including social inter... |
setwd("/Users/vrishtijain/Desktop/CLASS_FALL/DATA_ANALYTICS/PPTS")
library(tidyr)
library(tidyverse)
final_data<-read.csv("sleepdata.csv" , header=TRUE, sep = ";")
temp <- read.csv("sleepdata-preprocess.csv" , header=TRUE)
hello <-final_data$hours_start
temp$hours_start = hello
temp$Heart.rate = final_data$Heart.ra... | /sleep.R | no_license | vrishtijain/Analysis_of_sleep_data | R | false | false | 7,811 | r | setwd("/Users/vrishtijain/Desktop/CLASS_FALL/DATA_ANALYTICS/PPTS")
library(tidyr)
library(tidyverse)
final_data<-read.csv("sleepdata.csv" , header=TRUE, sep = ";")
temp <- read.csv("sleepdata-preprocess.csv" , header=TRUE)
hello <-final_data$hours_start
temp$hours_start = hello
temp$Heart.rate = final_data$Heart.ra... |
library(testthat)
library(sparseLRMatrix)
test_check("sparseLRMatrix")
| /tests/testthat.R | permissive | RoheLab/sparseLRMatrix | R | false | false | 72 | r | library(testthat)
library(sparseLRMatrix)
test_check("sparseLRMatrix")
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/political.R
\name{political}
\alias{political}
\title{Returns a probability distribution over the political alignment of the speaker}
\usage{
political(text, version = 2, ...)
}
\arguments{
\item{text}{text for analysis}
\item{version}{for a... | /man/political.Rd | permissive | denrou/IndicoIo-R | R | false | true | 1,248 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/political.R
\name{political}
\alias{political}
\title{Returns a probability distribution over the political alignment of the speaker}
\usage{
political(text, version = 2, ...)
}
\arguments{
\item{text}{text for analysis}
\item{version}{for a... |
=begin
=MessageMoveアクション
対象のメッセージを引数で指定されたフォルダに移動またはコピーします。
<<<selectedMessage.rd
引数には移動先のフォルダを指定します。移動先のフォルダは以下のいずれかの形式で指定します。
:フォルダの完全名
フォルダの完全名を指定した場合には、現在選択されているアカウントの指定された名前のフォルダを意味します。例えば、「受信箱/テスト」のように指定すると、「受信箱」の子フォルダの「テスト」フォルダを意味します。
:アカウント名+フォルダの完全名
アカウントまで含めて指定する場合には、フォルダの完全名の前に「//アカウント名/」... | /docs/MessageMoveAction.rd | permissive | snakamura/q3 | R | false | false | 1,631 | rd | =begin
=MessageMoveアクション
対象のメッセージを引数で指定されたフォルダに移動またはコピーします。
<<<selectedMessage.rd
引数には移動先のフォルダを指定します。移動先のフォルダは以下のいずれかの形式で指定します。
:フォルダの完全名
フォルダの完全名を指定した場合には、現在選択されているアカウントの指定された名前のフォルダを意味します。例えば、「受信箱/テスト」のように指定すると、「受信箱」の子フォルダの「テスト」フォルダを意味します。
:アカウント名+フォルダの完全名
アカウントまで含めて指定する場合には、フォルダの完全名の前に「//アカウント名/」... |
setwd('/Users/nigel/CCS_P6_C4/')
library(ggplot2)
library(gridExtra)
d = read.csv("combined_read_report.csv")
aggregate(ZMW~Algorithm,d,length)
dv = read.csv("combined_variant_report.csv")
aggregate(zmw~Algorithm,dv,length)
#get all sets
c4 = d$ZMW[d$Algorithm=="c4"]
C2 = d$ZMW[d$Algorithm=="C2"]
m = d$ZMW[d$Algorit... | /src/R/CompareExperiments.R | no_license | evolvedmicrobe/cafe-quality | R | false | false | 3,079 | r | setwd('/Users/nigel/CCS_P6_C4/')
library(ggplot2)
library(gridExtra)
d = read.csv("combined_read_report.csv")
aggregate(ZMW~Algorithm,d,length)
dv = read.csv("combined_variant_report.csv")
aggregate(zmw~Algorithm,dv,length)
#get all sets
c4 = d$ZMW[d$Algorithm=="c4"]
C2 = d$ZMW[d$Algorithm=="C2"]
m = d$ZMW[d$Algorit... |
#:# libraries
library(digest)
library(mlr)
library(OpenML)
library(farff)
#:# config
set.seed(1)
#:# data
dataset <- getOMLDataSet(data.name = "youtube")
head(dataset$data)
#:# preprocessing
head(dataset$data)
#:# model
task = makeClassifTask(id = "task", data = dataset$data, target = "gender")
lrn = makeLearner("c... | /models/openml_youtube/classification_gender/5386ba4fac924394b20000f086e5cdd1/code.R | no_license | pysiakk/CaseStudies2019S | R | false | false | 716 | r | #:# libraries
library(digest)
library(mlr)
library(OpenML)
library(farff)
#:# config
set.seed(1)
#:# data
dataset <- getOMLDataSet(data.name = "youtube")
head(dataset$data)
#:# preprocessing
head(dataset$data)
#:# model
task = makeClassifTask(id = "task", data = dataset$data, target = "gender")
lrn = makeLearner("c... |
#==========================================================================================#
#==========================================================================================#
# Function taylor.plot. This is similar to the taylor.diagram (package plotrix), with #
# some adaptations to make it more flexib... | /R-utils/taylor.plot.r | no_license | EDmodel/ED2 | R | false | false | 23,238 | r | #==========================================================================================#
#==========================================================================================#
# Function taylor.plot. This is similar to the taylor.diagram (package plotrix), with #
# some adaptations to make it more flexib... |
# run_analysis.R for Getting and Cleaning Data Course Project
# the unzipped files (4 text files and two folder) downloaded from https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip
# should be in the working directory of R, to determine root folder uncomment next line
# getwd()
# to... | /run_analysis.R | no_license | petermec/Getting-and-Cleaning-Data-Course-Project | R | false | false | 2,752 | r | # run_analysis.R for Getting and Cleaning Data Course Project
# the unzipped files (4 text files and two folder) downloaded from https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip
# should be in the working directory of R, to determine root folder uncomment next line
# getwd()
# to... |
testlist <- list(a = 9.97942358345792e-316, b = 0)
result <- do.call(BayesMRA::rmvn_arma_scalar,testlist)
str(result) | /BayesMRA/inst/testfiles/rmvn_arma_scalar/AFL_rmvn_arma_scalar/rmvn_arma_scalar_valgrind_files/1615926527-test.R | no_license | akhikolla/updatedatatype-list1 | R | false | false | 117 | r | testlist <- list(a = 9.97942358345792e-316, b = 0)
result <- do.call(BayesMRA::rmvn_arma_scalar,testlist)
str(result) |
#This code is indetended to run redundancy analyses, which may help define the most appropriate grid
#cell' size
#=====================================================================================================#
library(raster)
library(rgdal)
#====================================================================... | /scripts/Diplusodon/redundancy-diplusodon.R | no_license | souzayagob/no_one-size-fits-all | R | false | false | 4,709 | r | #This code is indetended to run redundancy analyses, which may help define the most appropriate grid
#cell' size
#=====================================================================================================#
library(raster)
library(rgdal)
#====================================================================... |
library(shiny)
shinyUI(pageWithSidebar(
# Application title
#headerPanel(),
# headerPanel(list(tags$head(tags$style("body {background-color: black; }")))),
headerPanel(
list(tags$head(tags$style("body {background-color: black; }")),
HTML('<p style="color:white"> IMDB Movie Ratings </p>' ))
)... | /homework2/ui.r | no_license | manoj-v/msan622 | R | false | false | 1,493 | r | library(shiny)
shinyUI(pageWithSidebar(
# Application title
#headerPanel(),
# headerPanel(list(tags$head(tags$style("body {background-color: black; }")))),
headerPanel(
list(tags$head(tags$style("body {background-color: black; }")),
HTML('<p style="color:white"> IMDB Movie Ratings </p>' ))
)... |
library(mlogit)
library(gmnl)
library(nnet)
library(dplyr)
#### DATA VISUALIZATION FUNCTIONS #######
Demand_Function <- function(data)
{
demand <- data %>% group_by(w, brandname) %>% summarise(Total_Sales=sum(q), Avg_Price=mean(price_per_unit))
return(ggplot(data = demand, mapping = aes(y = log(Total_Sales), x =... | /Estimation.R | no_license | sidgodb/Brand-Choice-Simulation | R | false | false | 2,982 | r |
library(mlogit)
library(gmnl)
library(nnet)
library(dplyr)
#### DATA VISUALIZATION FUNCTIONS #######
Demand_Function <- function(data)
{
demand <- data %>% group_by(w, brandname) %>% summarise(Total_Sales=sum(q), Avg_Price=mean(price_per_unit))
return(ggplot(data = demand, mapping = aes(y = log(Total_Sales), x =... |
# CI for continuous data
y <- c(35,34,38,35,37)
n <- length(y)
estimate <- mean(y)
se <- sd(y)/sqrt(n)
int.50 <- estimate + qt(c(.25,.75),n-1)*se
int.95 <- estimate + qt(c(.025,.975),n-1)*se
# CI for proportions
y <- 700
n <- 1000
estimate <- y/n
se <- sqrt (estimate*(1-estimate)/n)
int.95 <- estima... | /Gelman_BDA_ARM/doc/Book_Codes/Ch.2/2.3_CI.R | no_license | burakbayramli/books | R | false | false | 1,597 | r |
# CI for continuous data
y <- c(35,34,38,35,37)
n <- length(y)
estimate <- mean(y)
se <- sd(y)/sqrt(n)
int.50 <- estimate + qt(c(.25,.75),n-1)*se
int.95 <- estimate + qt(c(.025,.975),n-1)*se
# CI for proportions
y <- 700
n <- 1000
estimate <- y/n
se <- sqrt (estimate*(1-estimate)/n)
int.95 <- estima... |
# page no. 264
deltas = 0.0743
T1 = 460+100
cv = 0.219
T2 = T1*exp(deltas/cv)
print(T2)
| /Thermodynamics_And_Heat_Power_by_I_Granet_And_M_Bluestein/CH6/EX6.22/Ex6_22.R | permissive | FOSSEE/R_TBC_Uploads | R | false | false | 97 | r | # page no. 264
deltas = 0.0743
T1 = 460+100
cv = 0.219
T2 = T1*exp(deltas/cv)
print(T2)
|
### Graphical Test for Generalized Linear Autocorrelation Moving Average
### Functions with name test.* are run by R CMD check or by make if
### LEVEL=1 in call to make
### Functions with name levelntest.* are run by make if
### LEVEL=n in call to make
### Functions with name graphicstest.* are run by make if
### LEVE... | /inst/unitTests/runit.plot.glarma.R | no_license | cran/glarma | R | false | false | 2,547 | r | ### Graphical Test for Generalized Linear Autocorrelation Moving Average
### Functions with name test.* are run by R CMD check or by make if
### LEVEL=1 in call to make
### Functions with name levelntest.* are run by make if
### LEVEL=n in call to make
### Functions with name graphicstest.* are run by make if
### LEVE... |
## 2. Calculating expected values ##
males_over50k <- .67 * .241 * 32561
males_under50k <- .67 * .759 * 32561
females_over50k <- .33 * .241 * 32561
females_under50k <- .33 * .759 * 32561
## 3. Calculating the chi-squared statistic ##
chisq_gender_income <- 0
observed <- c(6662, 1179, 15128, 9592)
expected <- c(5257.... | /dataquest.io/hypothesis-testing-r/Multi category chi-squared tests-442.r | no_license | dougphaney/Lab_Python3 | R | false | false | 840 | r | ## 2. Calculating expected values ##
males_over50k <- .67 * .241 * 32561
males_under50k <- .67 * .759 * 32561
females_over50k <- .33 * .241 * 32561
females_under50k <- .33 * .759 * 32561
## 3. Calculating the chi-squared statistic ##
chisq_gender_income <- 0
observed <- c(6662, 1179, 15128, 9592)
expected <- c(5257.... |
# Homework 3 - Ben Lawee
# Sources outside of class (I had trouble with dplyr):
# https://dplyr.tidyverse.org/
# http://127.0.0.1:13308/library/dplyr/doc/programming.html
# https://datacarpentry.org/dc_zurich/R-ecology/04-dplyr.html
# https://dplyr.tidyverse.org/reference/desc.html
# https://dplyr.tidyverse.org/refere... | /BenLawee_Homework3.R | no_license | blawee/Homework-3 | R | false | false | 3,855 | r | # Homework 3 - Ben Lawee
# Sources outside of class (I had trouble with dplyr):
# https://dplyr.tidyverse.org/
# http://127.0.0.1:13308/library/dplyr/doc/programming.html
# https://datacarpentry.org/dc_zurich/R-ecology/04-dplyr.html
# https://dplyr.tidyverse.org/reference/desc.html
# https://dplyr.tidyverse.org/refere... |
setwd("~/Documents/7thSemester/dmp/corpus")
library("RSQLite")
library("tokenizers")
library("dplyr")
library("textclean")
library("stringr")
library("tm")
library(qdap)
# library(rJava)
# library("openNLPdata")
# paras first. like pale fire.
stock <- c("Title", "Type", "ID", "Unit", "Label")
life <- scan("rawTexts/l... | /scriptsAndDatabase/lyrical_clean/LIFEclean.R | no_license | timschott/dmp | R | false | false | 5,605 | r | setwd("~/Documents/7thSemester/dmp/corpus")
library("RSQLite")
library("tokenizers")
library("dplyr")
library("textclean")
library("stringr")
library("tm")
library(qdap)
# library(rJava)
# library("openNLPdata")
# paras first. like pale fire.
stock <- c("Title", "Type", "ID", "Unit", "Label")
life <- scan("rawTexts/l... |
##
## CalCulation for Figure 9 - effect of delay in reporting Singapore weekly data
##
rm(list = ls())
library("Hmisc")
library("zoo")
library("RColorBrewer")
horizon = 1:10
nhorizon = length(horizon)
require(DICE)
##
## select country using ISO-2 code
##
pdf = TRUE
##
## Disease to model
##
disease = 'dengue... | /make_figure9.R | permissive | predsci/Dengue | R | false | false | 11,066 | r | ##
## CalCulation for Figure 9 - effect of delay in reporting Singapore weekly data
##
rm(list = ls())
library("Hmisc")
library("zoo")
library("RColorBrewer")
horizon = 1:10
nhorizon = length(horizon)
require(DICE)
##
## select country using ISO-2 code
##
pdf = TRUE
##
## Disease to model
##
disease = 'dengue... |
context('Test filter_col')
test_that('test filter_col_q.zoocat and filter_col.zoocat', {
x <- matrix(1 : 20, nrow = 5)
colAttr <- data.frame(month = c(2, 3, 5, 6),
site = c('a', 'a', 'b', 'b'))
zc <- zoocat(x, order.by = 1991 : 1995, colattr = colAttr)
expect_equal(fi... | /data/genthat_extracted_code/zoocat/tests/test_filter_col.R | no_license | surayaaramli/typeRrh | R | false | false | 2,208 | r | context('Test filter_col')
test_that('test filter_col_q.zoocat and filter_col.zoocat', {
x <- matrix(1 : 20, nrow = 5)
colAttr <- data.frame(month = c(2, 3, 5, 6),
site = c('a', 'a', 'b', 'b'))
zc <- zoocat(x, order.by = 1991 : 1995, colattr = colAttr)
expect_equal(fi... |
library(magrittr)
library(data.table)
library(tidyverse)
library(tibble)
library(RColorBrewer)
library(GenomicRanges)
library(SummarizedExperiment)
library(vsn)
library(DESeq2)
library(ggpubr)
library(Polychrome)
# General parameters
bp = 750
chromosome = paste0('chr',1:22)
mark = 'CTCF'
data = 'Encode_twocells'
fdr =... | /Supp/Figure_Narrow_750bp/Figure_Correlation_CTCF_Encode_twocells_750bp.R | permissive | plbaldoni/epigraHMMPaper | R | false | false | 10,841 | r | library(magrittr)
library(data.table)
library(tidyverse)
library(tibble)
library(RColorBrewer)
library(GenomicRanges)
library(SummarizedExperiment)
library(vsn)
library(DESeq2)
library(ggpubr)
library(Polychrome)
# General parameters
bp = 750
chromosome = paste0('chr',1:22)
mark = 'CTCF'
data = 'Encode_twocells'
fdr =... |
# Encoding: utf8
fibonacci <- function(n, a=1, b=0, p=0, q=1) {
if(n==0)
return(b)
if(n%%2==0)
return(fibonacci(n/2,a,b,p*p+q*q,2*p*q+q*q))
return(fibonacci(n-1,a*p+a*q+b*q,b*p+a*q,p,q))
}
# 奇+偶=奇
# 奇+奇=偶
# 偶+偶=偶
# 排列顺序:奇奇偶奇奇偶奇奇偶...
# 用上面的fibonacci函数,取3n位置
s <- 0
i <- 1
repeat {
tmp <- fibonacci(3*i)
if(tmp ... | /Q001-050/Q002.R | no_license | equation85/ProjectEuler | R | false | false | 452 | r | # Encoding: utf8
fibonacci <- function(n, a=1, b=0, p=0, q=1) {
if(n==0)
return(b)
if(n%%2==0)
return(fibonacci(n/2,a,b,p*p+q*q,2*p*q+q*q))
return(fibonacci(n-1,a*p+a*q+b*q,b*p+a*q,p,q))
}
# 奇+偶=奇
# 奇+奇=偶
# 偶+偶=偶
# 排列顺序:奇奇偶奇奇偶奇奇偶...
# 用上面的fibonacci函数,取3n位置
s <- 0
i <- 1
repeat {
tmp <- fibonacci(3*i)
if(tmp ... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/idCEpos.R
\name{idCEpos}
\alias{idCEpos}
\title{Cholesterol Esthers (CE) annotation for ESI+}
\usage{
idCEpos(MS1, MSMS1, MSMS2, ppm_precursor = 5, ppm_products = 10,
rttol = 3, rt, adducts = c("2M+NH4", "2M+Na", "M+NH4", "M+Na"),
... | /man/idCEpos.Rd | no_license | 13479776/LipidMS | R | false | true | 5,169 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/idCEpos.R
\name{idCEpos}
\alias{idCEpos}
\title{Cholesterol Esthers (CE) annotation for ESI+}
\usage{
idCEpos(MS1, MSMS1, MSMS2, ppm_precursor = 5, ppm_products = 10,
rttol = 3, rt, adducts = c("2M+NH4", "2M+Na", "M+NH4", "M+Na"),
... |
#' Define mode limits by mouse clicks.
#'
#' This function allows to define limits for robust end-members by mouse clicks
#' on a combined plot output, showing a histogram and all end-members together.
#' Clicks must be placed in the order lower limit, upper limit - for each
#' end-member successively.
#'
#' @param d... | /EMMAgeo/R/define.limits.R | no_license | ingted/R-Examples | R | false | false | 2,344 | r | #' Define mode limits by mouse clicks.
#'
#' This function allows to define limits for robust end-members by mouse clicks
#' on a combined plot output, showing a histogram and all end-members together.
#' Clicks must be placed in the order lower limit, upper limit - for each
#' end-member successively.
#'
#' @param d... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{station_codes}
\alias{station_codes}
\title{National Rail Enquiries (NRE) Station Codes dataset}
\format{
A data frame with 2580 rows and 2 variables:
\describe{
\item{name}{Station name.}
\item{crs}{Station code.}... | /man/station_codes.Rd | no_license | cran/trainR | R | false | true | 627 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.R
\docType{data}
\name{station_codes}
\alias{station_codes}
\title{National Rail Enquiries (NRE) Station Codes dataset}
\format{
A data frame with 2580 rows and 2 variables:
\describe{
\item{name}{Station name.}
\item{crs}{Station code.}... |
add2 <- function(x, y) {
x + y
}
above10 <- function(x) {
use <- x > 10
x[use]swi
}
above <- function(x, n = 10) {
use <- x > n
x[use]
}
columnmean <- function(y, removeNA = TRUE) {
nc <- ncol(y)
means <- numeric(nc)
for (i in 1:nc) {
means[i] <- mean(y[, i], na.rm = removeNA)
}
means
}
| /RProgrammingClass/OtherScripts/functions.R | no_license | mattinata03/DataScienceSpecializationJHU-CompletedProjects | R | false | false | 315 | r | add2 <- function(x, y) {
x + y
}
above10 <- function(x) {
use <- x > 10
x[use]swi
}
above <- function(x, n = 10) {
use <- x > n
x[use]
}
columnmean <- function(y, removeNA = TRUE) {
nc <- ncol(y)
means <- numeric(nc)
for (i in 1:nc) {
means[i] <- mean(y[, i], na.rm = removeNA)
}
means
}
|
## ------------------------------------------------------------------------
library(CSOBam)
# for safe and testing purposes
library(tidyverse)
library(purrr)
library(magrittr)
| /vignettes/Intro.R | no_license | dmpe/CSOB_AssetManagement | R | false | false | 182 | r | ## ------------------------------------------------------------------------
library(CSOBam)
# for safe and testing purposes
library(tidyverse)
library(purrr)
library(magrittr)
|
test_that("Check if pathwayPredict output is list", {
x <- netSEMp1(acrylic)
paths <- pathwayRMSE(x, maxlen=3)
expect_type(pathwayPredict(x, paths[10,2]), "list")
}) | /tests/testthat/test-pathwayPredict.R | no_license | cran/netSEM | R | false | false | 179 | r | test_that("Check if pathwayPredict output is list", {
x <- netSEMp1(acrylic)
paths <- pathwayRMSE(x, maxlen=3)
expect_type(pathwayPredict(x, paths[10,2]), "list")
}) |
library(ape)
testtree <- read.tree("81_0.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="81_0_unrooted.txt") | /codeml_files/newick_trees_processed/81_0/rinput.R | no_license | DaniBoo/cyanobacteria_project | R | false | false | 131 | r | library(ape)
testtree <- read.tree("81_0.txt")
unrooted_tr <- unroot(testtree)
write.tree(unrooted_tr, file="81_0_unrooted.txt") |
### Sensitivity Analysis -------------------------------------------
names(data)
# strictly speaking, if 100% of taxon A is consumed and any of taxa B and C remain,
# preference for taxon A = 1 and preference for taxa B & C = -1
data$ostr.e[which(data$ostr.end == 0)] <- 1
data$cope.e[which(data$ostr.end == 0)] <- -1
... | /src/sensitivity_analysis.R | no_license | stanisauceg/2014_Feeding_Trials | R | false | false | 28,260 | r | ### Sensitivity Analysis -------------------------------------------
names(data)
# strictly speaking, if 100% of taxon A is consumed and any of taxa B and C remain,
# preference for taxon A = 1 and preference for taxa B & C = -1
data$ostr.e[which(data$ostr.end == 0)] <- 1
data$cope.e[which(data$ostr.end == 0)] <- -1
... |
#' @name ctd_rijpfjord
#' @title Example CTD data for Rijpfjorden
#' @description A dataframe containing example CTD data for Rijpfjorden.
#' @docType data
#' @usage data("ctd_rijpfjord")
#' @format data.frame
NULL
#' @name ctd_kongsfjord
#' @title Example CTD data for Kongsfjorden
#' @description A dataframe contai... | /R/dataset-docs.R | no_license | MikkoVihtakari/MarineDatabase | R | false | false | 2,571 | r | #' @name ctd_rijpfjord
#' @title Example CTD data for Rijpfjorden
#' @description A dataframe containing example CTD data for Rijpfjorden.
#' @docType data
#' @usage data("ctd_rijpfjord")
#' @format data.frame
NULL
#' @name ctd_kongsfjord
#' @title Example CTD data for Kongsfjorden
#' @description A dataframe contai... |
#' @useDynLib geometr
globalVariables(c("x", "y", "gtTheme", "fid", "gid", "vid", "targetGrob",
"include", "L1", "L2", "L3", "is_dup", "is_odd")) | /geometr/R/zzz.R | no_license | akhikolla/TestedPackages-NoIssues | R | false | false | 165 | r | #' @useDynLib geometr
globalVariables(c("x", "y", "gtTheme", "fid", "gid", "vid", "targetGrob",
"include", "L1", "L2", "L3", "is_dup", "is_odd")) |
#' Strip glm model.
#'
#' Strip the glm model, leaving only the necessary bits for doing a predict.
#'
#' @param cm The glm model to strip.
#'
#' @return Stripped glm model.
#'
#' @examples
#' data(iris)
#' iris$setosa <- ifelse(iris$Species == 'setosa', 1, 0)
#' sglm <- stripGlm(glm(setosa ~ Sepal.Length + Sepal.Width... | /R/models.R | no_license | utkusu/EPmisc | R | false | false | 1,564 | r | #' Strip glm model.
#'
#' Strip the glm model, leaving only the necessary bits for doing a predict.
#'
#' @param cm The glm model to strip.
#'
#' @return Stripped glm model.
#'
#' @examples
#' data(iris)
#' iris$setosa <- ifelse(iris$Species == 'setosa', 1, 0)
#' sglm <- stripGlm(glm(setosa ~ Sepal.Length + Sepal.Width... |
# Author: Komal S Rathi
# Date: 04/30/2019
# Function: split variant caller plots
# Step 2 (after using Mahdi's pipeline filters)
setwd('~/Projects/DGD_Mendelian_RNASeq/')
source('R/pubTheme.R')
library(reshape2)
library(ggplot2)
# samples
negative <- 'CDL-219-P'
samples <- read.delim('data/expression_data/patient_m... | /R/split_var_callers.R | no_license | komalsrathi/MendelianRNA-seq-analysis | R | false | false | 8,828 | r | # Author: Komal S Rathi
# Date: 04/30/2019
# Function: split variant caller plots
# Step 2 (after using Mahdi's pipeline filters)
setwd('~/Projects/DGD_Mendelian_RNASeq/')
source('R/pubTheme.R')
library(reshape2)
library(ggplot2)
# samples
negative <- 'CDL-219-P'
samples <- read.delim('data/expression_data/patient_m... |
shinyUI(pageWithSidebar(
# Application Title
headerPanel("Convert Degree Decimal (DD) Coordinates to Degrees Minutes Seconds(DMS)"),
sidebarPanel(
h2('Input the Degree Decimal Coordinates'),
numericInput('lat', 'Latitude in DD (90 to -90)', 00.0000, min = -90, max = 90, step =.1),
n... | /ui.R | no_license | cdo03c/ShinyApp | R | false | false | 619 | r | shinyUI(pageWithSidebar(
# Application Title
headerPanel("Convert Degree Decimal (DD) Coordinates to Degrees Minutes Seconds(DMS)"),
sidebarPanel(
h2('Input the Degree Decimal Coordinates'),
numericInput('lat', 'Latitude in DD (90 to -90)', 00.0000, min = -90, max = 90, step =.1),
n... |
# Load R packages
library(snowfall)
library(rlecuyer)
library(shadia)
# Initialize snowfall
sfInit(parallel=TRUE, cpus=7, type="SOCK")
# Define a function that can be called in parallel
# to run dam passage performance standard model
wrapper <- function(x) {
# Randomly sampling passage efficiencies
# Ups... | /connecticut_variable.R | no_license | danStich/shadia-cross-sectional | R | false | false | 4,635 | r | # Load R packages
library(snowfall)
library(rlecuyer)
library(shadia)
# Initialize snowfall
sfInit(parallel=TRUE, cpus=7, type="SOCK")
# Define a function that can be called in parallel
# to run dam passage performance standard model
wrapper <- function(x) {
# Randomly sampling passage efficiencies
# Ups... |
##############################
### EDA Dashboard
##############################
# id
eda_dashboard_id = "eda_dashboard"
# Sidebar
sidebar_eda <- menuItem("Exploració temporal", tabName = eda_dashboard_id, icon = icon("calendar"))
# Body
body_eda <- tabItem(tabName = eda_dashboard_id,
fluidRow(
useShinyjs(),
... | /01-barcelona-incidents-complaints-suggestions/dashboards/eda/ui_eda.R | no_license | marcfresquet/opendata-rshiny | R | false | false | 926 | r | ##############################
### EDA Dashboard
##############################
# id
eda_dashboard_id = "eda_dashboard"
# Sidebar
sidebar_eda <- menuItem("Exploració temporal", tabName = eda_dashboard_id, icon = icon("calendar"))
# Body
body_eda <- tabItem(tabName = eda_dashboard_id,
fluidRow(
useShinyjs(),
... |
#' Manage Tags in GTM
#'
#' @seealso https://developers.google.com/tag-manager/api/v2/reference/accounts/containers/workspaces/tags
#' @family tag functions
#' @export
gtm_tags_list <- function(account_id, container_id, workspace_id) {
if (any(missing(account_id),
missing(container_id),
missing(w... | /R/tags.R | permissive | MarkEdmondson1234/googleTagManageR | R | false | false | 4,243 | r | #' Manage Tags in GTM
#'
#' @seealso https://developers.google.com/tag-manager/api/v2/reference/accounts/containers/workspaces/tags
#' @family tag functions
#' @export
gtm_tags_list <- function(account_id, container_id, workspace_id) {
if (any(missing(account_id),
missing(container_id),
missing(w... |
#' @title Sample function for logs
#' @name slice_sample
#' @importFrom dplyr slice_sample
#' @export
dplyr::slice_sample
#' @describeIn slice_sample Sample \code{n} cases of a \code{\link{log}}.
#' @export
slice_sample.log <- function(.data, ..., n, prop, weight_by = NULL, replace = FALSE) {
n_cases <- n... | /R/slice_sample.R | no_license | cran/bupaR | R | false | false | 1,805 | r | #' @title Sample function for logs
#' @name slice_sample
#' @importFrom dplyr slice_sample
#' @export
dplyr::slice_sample
#' @describeIn slice_sample Sample \code{n} cases of a \code{\link{log}}.
#' @export
slice_sample.log <- function(.data, ..., n, prop, weight_by = NULL, replace = FALSE) {
n_cases <- n... |
code_files_raw <- list.files("code", full.names = TRUE)
code_files <- code_files_raw[!grepl("00A|00B|00C|00D", code_files_raw)]
purrr::walk(
code_files,
function(y) {
message("\n###### ", y, " ######\n")
source(y, local = T)
rm(list = ls())
}
)
| /code/00C_run_all_scripts.R | permissive | nevrome/olympia.votiveweapons.article2021 | R | false | false | 264 | r | code_files_raw <- list.files("code", full.names = TRUE)
code_files <- code_files_raw[!grepl("00A|00B|00C|00D", code_files_raw)]
purrr::walk(
code_files,
function(y) {
message("\n###### ", y, " ######\n")
source(y, local = T)
rm(list = ls())
}
)
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/parallel_vboot.R
\name{vboot.glm}
\alias{vboot.glm}
\title{Internal bootstraping validation logistic model}
\usage{
\method{vboot}{glm}(fit, x = NULL, y = NULL, s = NULL, nfolds = NULL,
B = 200, cv_replicates = NULL, lambda = NULL, n... | /man/vboot.glm.Rd | no_license | cran/BootValidation | R | false | true | 1,359 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/parallel_vboot.R
\name{vboot.glm}
\alias{vboot.glm}
\title{Internal bootstraping validation logistic model}
\usage{
\method{vboot}{glm}(fit, x = NULL, y = NULL, s = NULL, nfolds = NULL,
B = 200, cv_replicates = NULL, lambda = NULL, n... |
rm(list=ls())
# data1 <- read.csv("G:\\Srinath\\Datasets\\UniversalBank.csv")
data1 <- read.csv("D:\\DataScience_Drive\\universalBank.csv")
View(data1)
str(data1)
# length(unique(data1$ZIP.Code))
data1$ZIP.Code <- NULL
str(data1)
data1$ID <- NULL
data1$Personal.Loan <- as.factor(data1$Personal.Loan)
dat... | /Boosting.R | no_license | SivaGanesh034/Bank_dataset | R | false | false | 4,264 | r | rm(list=ls())
# data1 <- read.csv("G:\\Srinath\\Datasets\\UniversalBank.csv")
data1 <- read.csv("D:\\DataScience_Drive\\universalBank.csv")
View(data1)
str(data1)
# length(unique(data1$ZIP.Code))
data1$ZIP.Code <- NULL
str(data1)
data1$ID <- NULL
data1$Personal.Loan <- as.factor(data1$Personal.Loan)
dat... |
library(cvTools)
### Name: summary.cv
### Title: Summarize cross-validation results
### Aliases: summary.cv summary.cvSelect summary.cvTuning
### Keywords: utilities
### ** Examples
library("robustbase")
data("coleman")
set.seed(1234) # set seed for reproducibility
## set up folds for cross-validation
folds <- cv... | /data/genthat_extracted_code/cvTools/examples/summary.cv.Rd.R | no_license | surayaaramli/typeRrh | R | false | false | 1,412 | r | library(cvTools)
### Name: summary.cv
### Title: Summarize cross-validation results
### Aliases: summary.cv summary.cvSelect summary.cvTuning
### Keywords: utilities
### ** Examples
library("robustbase")
data("coleman")
set.seed(1234) # set seed for reproducibility
## set up folds for cross-validation
folds <- cv... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/misc.R
\name{query}
\alias{query}
\title{Takes a custom query, issues a request to the API, and returns the results
in form of a dataframe.}
\usage{
query(myquery, apiKey)
}
\arguments{
\item{myquery}{An "EXEC ..." string.}
\item{apiKey}{The... | /cmap4r/man/query.Rd | no_license | simonscmap/cmap4r | R | false | true | 448 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/misc.R
\name{query}
\alias{query}
\title{Takes a custom query, issues a request to the API, and returns the results
in form of a dataframe.}
\usage{
query(myquery, apiKey)
}
\arguments{
\item{myquery}{An "EXEC ..." string.}
\item{apiKey}{The... |
setwd("C:/Users/Vishakha Sangwan/Downloads/R directory")
#Reading Data
data <- read.csv('household_power_consumption.txt', header=T, sep=';', na.strings="?",
nrows=2075259, check.names=F, stringsAsFactors=F, comment.char="", quote='\"')
data$Date <- as.Date(data$... | /plot 1.R | no_license | Vishakha2106/Exploratory-Data-analysis | R | false | false | 872 | r |
setwd("C:/Users/Vishakha Sangwan/Downloads/R directory")
#Reading Data
data <- read.csv('household_power_consumption.txt', header=T, sep=';', na.strings="?",
nrows=2075259, check.names=F, stringsAsFactors=F, comment.char="", quote='\"')
data$Date <- as.Date(data$... |
#' SSGA summary
#'
#' Summarize an object of class type 'ssga'
#' @param ssga.obj An object of class 'ssga' created using \code{ssga}
#' @examples
#' ## Load ICU workspace (from aplore3 package)
#' load(system.file('extdata', 'ssga_icu_ws.RData', package = 'ssga'))
#' summary(ssga.obj)
#'
#' ## Load Swiss work... | /R/summary.ssga.R | no_license | tjmassaro/ssga | R | false | false | 2,629 | r | #' SSGA summary
#'
#' Summarize an object of class type 'ssga'
#' @param ssga.obj An object of class 'ssga' created using \code{ssga}
#' @examples
#' ## Load ICU workspace (from aplore3 package)
#' load(system.file('extdata', 'ssga_icu_ws.RData', package = 'ssga'))
#' summary(ssga.obj)
#'
#' ## Load Swiss work... |
library(tools)
library(devtools)
library(rga)
key_words = "diarypost/diary"
smart_pc_list = list(30593836, 26708871)
list_name = list("smart", "pc");
initial.options <- commandArgs(trailingOnly = FALSE)
file.arg.name <- "--file="
script.name <- sub(file.arg.name, "", initial.options[grep(file.arg.name, initial.option... | /recruit_edit.R | no_license | kamelzcs/google-analytics | R | false | false | 2,050 | r | library(tools)
library(devtools)
library(rga)
key_words = "diarypost/diary"
smart_pc_list = list(30593836, 26708871)
list_name = list("smart", "pc");
initial.options <- commandArgs(trailingOnly = FALSE)
file.arg.name <- "--file="
script.name <- sub(file.arg.name, "", initial.options[grep(file.arg.name, initial.option... |
pop<-100
K<-1000
pop.hist<-c()
r<-0.05
for (i in 1:150) {
pop.hist[i]<-pop
pop <- pop*exp(r*(1-(pop/K)))
}
plot(pop.hist)
| /pop2.R | no_license | RileyPBall/chem160homework7 | R | false | false | 133 | r | pop<-100
K<-1000
pop.hist<-c()
r<-0.05
for (i in 1:150) {
pop.hist[i]<-pop
pop <- pop*exp(r*(1-(pop/K)))
}
plot(pop.hist)
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.r
\docType{data}
\name{howard28}
\alias{howard28}
\title{Lumber production, imports, exports, and consumption, by softwoods and hardwoods, 1965-1999.}
\format{A data frame with 56 observations of 15 variables:
\describe{
\item{Prod.Tot}{... | /man/howard28.Rd | no_license | alanarnholt/WOODCARB3R | R | false | true | 1,270 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/data.r
\docType{data}
\name{howard28}
\alias{howard28}
\title{Lumber production, imports, exports, and consumption, by softwoods and hardwoods, 1965-1999.}
\format{A data frame with 56 observations of 15 variables:
\describe{
\item{Prod.Tot}{... |
function (dvs)
{
e <- get("data.env", .GlobalEnv)
e[["dseatsDVS"]][[length(e[["dseatsDVS"]]) + 1]] <- list(dvs = dvs)
.Call("_redist_dseatsDVS", dvs)
}
| /valgrind_test_dir/dseatsDVS-test.R | no_license | akhikolla/RcppDeepStateTest | R | false | false | 165 | r | function (dvs)
{
e <- get("data.env", .GlobalEnv)
e[["dseatsDVS"]][[length(e[["dseatsDVS"]]) + 1]] <- list(dvs = dvs)
.Call("_redist_dseatsDVS", dvs)
}
|
rm=(list=ls())
library(mosaic)
library(readxl)
L4E6 <- read_excel("D:/IM课程/Moodle 1.3/Exercises Excel files-20201118/Lecture 4/L4E6.xlsx")
View(L4E6)
attach(L4E6)
raw <- RAW
confint(raw,level = 0.95)
mean(raw)
sd_pop=sd(raw)/sqrt(38)
t.test(raw,conf.level = 0.95)
(5.5-mean(raw))/sd_pop
| /Exercise/List 4/list4-06.R | no_license | Fayehh/R-for-Quantitative-Research | R | false | false | 307 | r | rm=(list=ls())
library(mosaic)
library(readxl)
L4E6 <- read_excel("D:/IM课程/Moodle 1.3/Exercises Excel files-20201118/Lecture 4/L4E6.xlsx")
View(L4E6)
attach(L4E6)
raw <- RAW
confint(raw,level = 0.95)
mean(raw)
sd_pop=sd(raw)/sqrt(38)
t.test(raw,conf.level = 0.95)
(5.5-mean(raw))/sd_pop
|
#!/usr/bin/Rscript
install.packages("igraph")
library(igraph)
# VISUALIZING NETWORK DATA
####################################################################################
# PROBLEM 1 - SUMMARIZING THE DATA
# Loading data from csv
edges = read.csv("edges.csv")
users = read.csv("users.csv")
# How many Facebook users ... | /AnalyticsEdge/Complete/Week 8/network/network.R | no_license | sivansasidharan/Edx-References | R | false | false | 1,606 | r | #!/usr/bin/Rscript
install.packages("igraph")
library(igraph)
# VISUALIZING NETWORK DATA
####################################################################################
# PROBLEM 1 - SUMMARIZING THE DATA
# Loading data from csv
edges = read.csv("edges.csv")
users = read.csv("users.csv")
# How many Facebook users ... |
context("Test DetRules 1 and k")
test_that("A simple test for rule Generation of consequent_length one", {
FrequentItems <- Rpriori:::DetRules_1_FrequentItemets
FrequentItems <- new("FIMatrix",
data = as(FrequentItems, "ngTMatrix"),
support = Rpriori:::DetRules_... | /tests/testthat/test-DetRules.r | no_license | abuchmueller/Rpriori | R | false | false | 2,269 | r | context("Test DetRules 1 and k")
test_that("A simple test for rule Generation of consequent_length one", {
FrequentItems <- Rpriori:::DetRules_1_FrequentItemets
FrequentItems <- new("FIMatrix",
data = as(FrequentItems, "ngTMatrix"),
support = Rpriori:::DetRules_... |
tab = read.table("programs.txt", header = TRUE, sep = "\t" )
head(tab)
summary(tab)
###############################################################################
# Question 1
## Nombre de programmes par langage
pdf('rapport/figures/prog_lang.pdf')
barplot(table(tab$Language),
main = "Nombre de programmes p... | /Freire_Legrand-Duchesne.R | no_license | johnlepoulpe/urban-funicular | R | false | false | 5,888 | r | tab = read.table("programs.txt", header = TRUE, sep = "\t" )
head(tab)
summary(tab)
###############################################################################
# Question 1
## Nombre de programmes par langage
pdf('rapport/figures/prog_lang.pdf')
barplot(table(tab$Language),
main = "Nombre de programmes p... |
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{create_feature_named_list}
\alias{create_feature_named_list}
\title{Create Feature Named List}
\usage{
create_feature_named_list(class_ids = NA, sample_ids = NA)
}
\arguments{
\item{class_ids}{Integers in the id column of the cl... | /man/create_feature_named_list.Rd | permissive | Drinchai/iatlas-app | R | false | true | 456 | rd | % Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{create_feature_named_list}
\alias{create_feature_named_list}
\title{Create Feature Named List}
\usage{
create_feature_named_list(class_ids = NA, sample_ids = NA)
}
\arguments{
\item{class_ids}{Integers in the id column of the cl... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.