Package: CodeDepends 0.6.6.1

Gabriel Becker

CodeDepends: Analysis of R Code for Reproducible Research and Code Comprehension

Tools for analyzing R expressions or blocks of code and determining the dependencies between them. It focuses on R scripts, but can be used on the bodies of functions. There are many facilities including the ability to summarize or get a high-level view of code, determining dependencies between variables, code improvement suggestions.

Authors:Duncan Temple Lang, Roger Peng, Deborah Nolan, Gabriel Becker

CodeDepends_0.6.6.1.tar.gz
CodeDepends_0.6.6.1.zip(r-4.5)CodeDepends_0.6.6.1.zip(r-4.4)CodeDepends_0.6.6.1.zip(r-4.3)
CodeDepends_0.6.6.1.tgz(r-4.4-any)CodeDepends_0.6.6.1.tgz(r-4.3-any)
CodeDepends_0.6.6.1.tar.gz(r-4.5-noble)CodeDepends_0.6.6.1.tar.gz(r-4.4-noble)
CodeDepends_0.6.6.1.tgz(r-4.4-emscripten)CodeDepends_0.6.6.1.tgz(r-4.3-emscripten)
CodeDepends.pdf |CodeDepends.html
CodeDepends/json (API)
NEWS

# Install 'CodeDepends' in R:
install.packages('CodeDepends', repos = c('https://duncantl.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/duncantl/codedepends/issues

On CRAN:

6.89 score 89 stars 1 packages 73 scripts 382 downloads 52 exports 5 dependencies

Last updated 1 years agofrom:7fd96dfee1. Checks:OK: 3 NOTE: 4. Indexed: yes.

TargetResultDate
Doc / VignettesOKNov 14 2024
R-4.5-winNOTENov 14 2024
R-4.5-linuxNOTENov 14 2024
R-4.4-winNOTENov 14 2024
R-4.4-macNOTENov 14 2024
R-4.3-winOKNov 14 2024
R-4.3-macOKNov 14 2024

Exports:addRemoveIntermediatesapplyhandlerfactoryassignfunhandlerassignhandlerasVarNamecoercecolonshandlercounthandlerdatahandlerdefaultFuncHandlersdefhandlerdollarhandlerfilterhandlerfindWhenUnneededforhandlerformulahandlerfullnsehandlerfunchandlerfunshandlergetDependsThreadgetDetailedTimelinesgetExpressionThreadgetInputsgetPropagateChangesgetSectionDependsgetVariableDependsgetVariablesgroupbyhandlerguessTaskTypehighlightCodehistoryAsScriptinputCollectorlibreqhandlermakeCallGraphmakeTaskGraphmakeVariableGraphnoophandlernseafterfirstnsehandlerfactorynseonlyhandlerfactorypipehandlerreadAnnotatedScriptreadScriptrmhandlerrunUpToSectionscriptInfoseparateExpressionBlockssourceVariablesplitRedefinitionsspreadhandlersummarize_handlerfactoryupdatingScript

Dependencies:BiocGenericscodetoolsgenericsgraphXML

CodeDepends: Static analysis and dependency detection for R code

Rendered fromintro.Rmdusingknitr::rmarkdownon Nov 14 2024.

Last update: 2023-10-21
Started: 2017-05-27

Readme and manuals

Help Manual

Help pageTopics
asVarNameasVarName
Determine the code block after which a variable can be explicitly removedaddRemoveIntermediates findWhenUnneeded
Specifying custom processing behavior, Function handlers and handler factoriesapplyhandlerfactory assignfunhandler assignhandler colonshandler counthandler datahandler defaultFuncHandlers defhandler dollarhandler filterhandler forhandler formulahandler fullnsehandler funchandler functionhandlers funshandler groupbyhandler libreqhandler noophandler nseafterfirst nsehandlerfactory nseonlyhandlerfactory pipehandler rmhandler spreadhandler summarize_handlerfactory
Compute which code blocks in a script are inputs to define a variablegetDependsThread getDependsThread,character-method getDependsThread,name-method getDependsThread,numeric-method
Compute and plot life cycle of variables in codecoerce,DetailedVariableTimeline,matrix-method getDetailedTimelines plot.DetailedVariableTimeline
Find the sequence of expressions needed to get to a certain point in the codegetExpressionThread
Get input and output variables and literals from R expressionsgetInputs getInputs,ANY-method getInputs,function-method getInputs,Script-method getInputs,ScriptNode-method getInputs,ScriptNodeInfo-method scriptInfo
Determine which expressions to update when a variable changesgetPropagateChanges
Determine dependencies for code blocksgetSectionDepends getVariableDepends
Get the names of the variables used in codegetVariables getVariables,expression-method getVariables,Script-method getVariables,ScriptInfo-method getVariables,ScriptNode-method getVariables,ScriptNodeInfo-method
Guess the type of high-level task of a code blockguessTaskType
Display R code with highlighting of variables, links to functions and packageshighlightCode
Convert R interactive history to a Script objecthistoryAsScript
Create customized input/output collector for use in getInputsinputCollector
Create a graph representing which functions call other functionsmakeCallGraph makeCallGraph,character-method makeCallGraph,function-method makeCallGraph,list-method
Create a graph connecting the tasks within a scriptmakeTaskGraph
Create a graph describing the relationships between variables in a scriptmakeVariableGraph
Read the code blocks/chunks from a documentreadAnnotatedScript readScript readScript,character-method readScript,connection-method readScript,missing-method readScript,XMLInternalDocument-method
Evaluate the code blocks up to a particular section of a documentrunUpToSection
The Script class and elements$,Script-method AnnotatedScript-class coerce,expression,ScriptNodeInfo-method coerce,language,ScriptNodeInfo-method coerce,Script,ScriptInfo-method coerce,ScriptNode,ScriptNodeInfo-method Script-class ScriptInfo-class ScriptNode-class ScriptNodeInfo-class [,Script,character,missing-method [,Script,vector,missing-method
Convert a script into individual top-level callsseparateExpressionBlocks
Evaluate code in document in order to define the specified variablessourceVariable
Divide a script into separate lists of code based on redefinition of a variablesplitRedefinitions
Create a Script object that re-reads the original file as neededcoerce,DynScript,Script-method getInputs,DynScript-method updatingScript