Learn R Programming

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

statnet.common (version 4.9.0)

Common R Scripts and Utilities Used by the Statnet Project Software

Description

Non-statistical utilities used by the software developed by the Statnet Project. They may also be of use to others.

Copy Link

Version

Install

install.packages('statnet.common')

Monthly Downloads

34,342

Version

4.9.0

License

GPL-3 + file LICENSE

Maintainer

Pavel N. Krivitsky

Last Published

May 24th, 2023

Functions in statnet.common (4.9.0)

deprecation-utilities

Utilities to help with deprecating functions.
despace

A one-line function to strip whitespace from its argument.
deInf

Truncate values of high magnitude in a vector.
default_options

Set options() according to a named list, skipping those already set.
diff.control.list

Identify and the differences between two control lists.
control.remap

Overwrite control parameters of one configuration with another.
forkTimeout

Evaluate an R expression with a hard time limit by forking a process
formula.utilities

Functions for Querying, Validating and Extracting from Formulas
empty_env

Replace an object's environment with a simple, static environment.
fixed.pval

Format a p-value in fixed notation.
paste.and

Concatenates the elements of a vector (optionaly enclosing them in quotation marks or parentheses) adding appropriate punctuation and conjunctions.
persistEval

Evaluate an expression, restarting on error
once

Evaluate a function once for a given input.
opttest

Optionally test code depending on environment variable.
mcmc-utilities

Utility operations for mcmc.list objects
split.array

A split() method for array and matrix types on a margin.
simplify_simple

Convert a list to an atomic vector if it consists solely of atomic elements of length 1.
set.control.class

Set the class of the control list
is.SPD

Test if the object is a matrix that is symmetric and positive definite
message_print

print objects to the message output.
snctrl

Statnet Control
handle.controls

Handle standard control.*() function semantics.
locate_function

Locate a function with a given name and return it and its environment.
print.control.list

Pretty print the control list
snctrl_names

Helper functions used by packages to facilitate snctrl updating.
order

Implement the sort and order methods for data.frame and matrix, sorting it in lexicographic order.
logspace.utils

Utilities for performing calculations on logarithmic scale.
vector.namesmatch

reorder vector v into order determined by matching the names of its elements to a vector of names
statnet.cite

CITATION file utilities for Statnet packages (DEPRECATED)
wmatrix

A data matrix with row weights
wmatrix_weights

Set or extract weighted matrix row weights
statnetStartupMessage

Construct a "standard" startup message to be printed when the package is loaded.
xTAx

Common quadratic forms
ult

Extract or replace the ultimate (last) element of a vector or a list, or an element counting from the end.
trim_env

Make a copy of an environment with just the selected objects.
term_list

A helper class for list of terms in an formula
sweep_cols.matrix

Suptract a elements of a vector from respective columns of a matrix
unused_dots_warning

An error handler for rlang::check_dots_used() that issues a warning that only lists argument names.
ssolve

Wrappers around matrix algebra functions that pre-scale their arguments
unwhich

Construct a logical vector with TRUE in specified positions.
ERRVL

attr

A wrapper for base::attr which defaults to exact matching.
all_identical

Test if all items in a vector or a list are identical.
as.control.list

Convert to a control list.
Welford

A Welford accumulator for sample mean and variance
compress_rows

A generic function to compress a row-weighted table
check.control.class

Ensure that the class of the control list is one of those that can be used by the calling function
control.list.accessor

Named element accessor for ergm control lists
compress_rows.data.frame

"Compress" a data frame.
NVL