Learn R Programming

⚠️There's a newer version (3.5.1) of this package.Take me there.

Cyclops

Introduction

Cyclops (Cyclic coordinate descent for logistic, Poisson and survival analysis) is an R package for performing large scale regularized regressions.

Features

  • Regression of very large problems: up to millions of observations, millions of variables
  • Supports (conditional) logistic regression, (conditional) Poisson regression, as well as (conditional) Cox regression
  • Uses a sparse representation of the independent variables when appropriate
  • Supports using no prior, a normal prior or a Laplace prior
  • Supports automatic selection of hyperparameter through cross-validation
  • Efficient estimation of confidence intervals for a single variable using a profile-likelihood for that variable

Examples

  library(Cyclops)
  cyclopsData <- createCyclopsDataFrame(formula)
  cyclopsFit <- fitCyclopsModel(cyclopsData)

Technology

Cyclops in an R package, with most functionality implemented in C++. Cyclops uses cyclic coordinate descent to optimize the likelihood function, which makes use of the sparse nature of the data.

System Requirements

Requires R (version 3.1.0 or higher). Installation on Windows requires RTools (devtools >= 1.12 required for RTools34, otherwise RTools33 works fine).

Dependencies

  • There are no dependencies.

Getting Started

  1. On Windows, make sure RTools is installed.
  2. In R, use the following commands to download and install Cyclops:
install.packages("devtools")
library(devtools)
install_github("ohdsi/Cyclops") 
  1. To perform a Cyclops model fit, use the following commands in R:
library(Cyclops)
cyclopsData <- createCyclopsDataFrame(formula)
cyclopsFit <- fitCyclopsModel(cyclopsData)

Getting Involved

  • Package manual: Cyclops manual
  • Developer questions/comments/feedback: OHDSI Forum
  • We use the GitHub issue tracker for all bugs/issues/enhancements

License

Cyclops is licensed under Apache License 2.0. Cyclops contains the TinyThread libray.

The TinyThread library is licensed under the zlib/libpng license as described here.

Development

Cyclops is being developed in R Studio.

###Development status

Beta

Acknowledgements

  • This project is supported in part through the National Science Foundation grants IIS 1251151 and DMS 1264153.

Copy Link

Version

Install

install.packages('Cyclops')

Monthly Downloads

1,173

Version

1.2.0

License

Apache License 2.0

Issues

Pull Requests

Stars

Forks

Maintainer

Marc A Suchard

Last Published

August 1st, 2016

Functions in Cyclops (1.2.0)

convertToGlmnetLambda

Convert to glmnet regularization parameter
coverage

Coverage
appendSqlCyclopsData

appendSqlCyclopsData
confint.cyclopsFit

Confidence intervals for Cyclops model parameters
aconfint

Asymptotic confidence intervals for a fitted Cyclops model object
convertToCyclopsVariance

Convert to Cyclops Prior Variance
createCyclopsData

Create a Cyclops data object
coef.cyclopsFit

Extract model coefficients
createControl

Create a Cyclops control object
convertToCyclopsData

Convert data from two data frames or ffdf objects into a CyclopsData object
getHyperParameter

Get hyperparameter
fitCyclopsSimulation

Fit simulated data
getNumberOfCovariates

Get total number of covariates
getCovariateIds

Get covariate identifiers
createPrior

Create a Cyclops prior object
getCovariateTypes

Get covariate types
getCyclopsPredictiveLogLikelihood

Compute predictive log-likelihood from a Cyclops model fit
cyclops

Cyclops: Cyclic coordinate descent for logistic, Poisson and survival analysis
getUnivariableCorrelation

Get univariable correlation
isInitialized

Check if a Cyclops data object is initialized
isSorted

Check if data are sorted by one or more columns
getNumberOfRows

Get total number of rows
logLik.cyclopsFit

Extract log-likelihood
getNumberOfStrata

Get number of strata
fitCyclopsModel

Fit a Cyclops model
finalizeSqlCyclopsData

finalizeSqlCyclopsData
mse

Mean squared error
simulateCyclopsData

Simulation Cyclops dataset
summary.cyclopsData

Cyclops data object summary
Multitype

Create a multitype outcome object
predict.cyclopsFit

Model predictions
print.cyclopsData

Print a Cyclops data object
readCyclopsData

Read Cyclops data from file
reduce

Apply simple data reductions
oxford

Oxford self-controlled case series data
printCyclopsRowIds

Print row identifiers
getNumberOfTypes

Get total number of outcome types
print.cyclopsFit

Print a Cyclops model fit object
getSEs

Extract standard errors
plotCyclopsSimulationFit

Plot Cyclops simulation model fit
vcov.cyclopsFit

Calculate variance-covariance matrix for a fitted Cyclops model object