Wolfram Research


Programming Utilities

170 items

  • AbortOnMessage

    Abort an evaluation as soon as a message is generated

  • AddCodeCompletion

    Adds code completion to your function’s arguments

  • AppendSequence

    Append multiple items to an expression at once

  • ArgumentCount

    Count the number of arguments a pure function or compiled function takes

  • AsynchronousDynamicModule

    A wrapper function for dynamic modules which causes a placeholder to be shown during initialization

  • BenchmarkPlot

    Plot the timings of a benchmark

  • BinarySearch

    Find the position of a target value within a sorted array

  • BinarySearchBy

    Find the position of a target value within an array sorted after applying a function

  • BinarySerializeWithDefinitions

    Serialize an expression along with any dependent definitions

  • BinListsBy

    Bins data in to lists based on applying a function to each item.

  • BitFlip

    Flip an individual bit in an integer (0 to 1 and 1 to 0)

  • BitListToByteArray

    Convert a list of bits to a byte array

  • BoolEval

    Fast vectorized evaluation of array inequalities

  • ByteArrayToBitList

    Converts a byte array to a list of bits

  • BytesToQuantity

    Convert a byte count to a quantity of bytes in an appropriate unit

  • CacheTo

    Return a stored expression if it exists; otherwise, evaluate and store an expression

  • CatchAll

    Get $Aborted for uncaught Throw or Abort in an evaluation

  • CatchFailure

    Catches any Failure object thrown by an enclosed ThrowFailure evaluation

  • CellObjectStyle

    Get the style of given CellObject

  • ChannelMessages

    Send relevant data to a channel object when a message occurs

  • CheckHyperlinks

    Checks hyperlinks in an expression, webpage, or notebook, on your computer or in the cloud

  • CheckMatch

    Verify that an evaluation output matches a given pattern and produces no errors

  • CheckReturn

    Evaluates an expression and returns the result, unless messages were generated, in which case it immediately returns a failure expression

  • ChromaticNumber

    Compute the vertex chromatic number of a graph

  • CloudObjectBase

    Get the cloud base for a cloud object

  • CloudPutByHash

    CloudPut to a location determined by the hash of an expression

  • CloudResourceFunction

    Access functions deployed to your own or another user’s Wolfram Cloud account that are not in the official Function Repository

  • CompressWithDefinitions

    Compress an expression, along with any needed definitions, so that it can be used in another session

  • ContextDependencies

    Determine how symbols in a first context depend on symbols in a second context

  • ContextModule

    Temporarily set $Context and $ContextPath to a unique empty context for an evaluation

  • CopyDefinitions

    Copy the definitions of one symbol to another

  • CreatePackageEventHandler

    Create an event handler that evaluates an expression when a package is loaded

  • DatasetForm

    Display data formatted like a dataset

  • DeclareArgumentCount

    Set up a symbol to give an error message when called with an unexpected number of arguments

  • DefinitionData

    Store full definitions for a symbol in a compact object

  • DeleteFailures

    Delete failures in an expression

  • DirectoryBlock

    Temporarily change the current directory for an evaluation and ensure that it is restored when evaluation is completed

  • DropTrailingWhile

    Drop elements at the end of a list so long as a criterion is fulfilled

  • DropWhile

    Drop elements of a list while a criterion remains true

  • DynamicListView

    Display the contents of a list with dynamic controls for paging and skimming

  • DynamicMap

    Map functions over lists while showing dynamic progress

  • EchoEvaluate

    Debug applications of a function more easily by printing its arguments and the result

  • EchoIf

    A curried form of Echo that can be useful in certain debugging situations

  • EchoNormal

    Print the code in InputForm unformatted

  • EchoSet

    Set a value to a symbol and print them

  • EchoTiming

    Print the timing for an evaluation and return the result

  • EnsureDirectory

    Ensure that a directory exists, no matter what

  • EnsureFilePath

    Create the parent directories necessary to fill out a given file path

  • EvaluateBenchmark

    Measure the evaluation timings of a function on a given set of inputs

  • EvaluateDefinitionNotebookSection

    Evaluate code in a resource function definition notebook

  • EvaluationStatusUpdate

    Give status updates while your code is running

  • EvaluationTiming

    Get a full timing report for functions evaluated during an evaluation

  • Excise

    Remove enclosed arguments

  • ExpressionBag

    A data structure meant for accumulating items efficiently

  • ExpressionToFunction

    Convert an expression to a pure function by specifying which symbols should be used as input arguments

  • ExpressionViewer

    A dynamic tool that helps visualize the structure of an expression

  • ExtractDownValues

    Extract all DownValues that match the input

  • FailOnMessage

    Stop an evaluation when a message is encountered and return a given failure expression

  • FileFormatQ

    Test if a file is in the specified format

  • FindRanges

    Find continuous ranges in a list of integers

  • FirstMatchingValue

    Evaluate expressions in turn until a given form is returned

  • FormatAsResourceFunction

    Format a symbol as a ResourceFunction in outputs

  • FromRecursiveRewrite

    Recover expressions using RecursiveRewrite generated rules

  • FullSymbolName

    Return a fully qualified name of a symbol regardless of current context settings

  • GetKeyValuePattern

    Create a suitable KeyValuePattern from an example association

  • GetUnboundSymbols

    Get all the non-local symbols that appear in an expression

  • GraphicsBounds

    Get the plot range used in a piece of graphics

  • GroupByList

    Group elements according to a list of equivalence classes

  • HasDefinitionsQ

    Check if a symbol has definitions associated with it

  • HoldArguments

    Construct a function from another function that holds certain arguments

  • ImportOnce

    A version of Import which uses a cache of the result unless the source file has changed

  • InheritedBlock

    Similar to Block, except values of local symbols are not cleared when entering the block

  • Inline

    Insert the values of symbols into an expression before evaluation

  • InspectNotebook

    Launch a dynamic display showing the selected notebook content

  • InterpretedTrueQ

    Determine if a value should be interpreted as true

  • JoinTo

    Equivalent to Join, but redefines the first argument to the result

  • KernelStatusGrid

    Display all named kernels that are currently defined, their current status, the process IDs of those that are running and some additional useful controls

  • LabeledPrint

    Print an expression with a label of its unevaluated form

  • LocalEvaluate

    Synchronously evaluate an expression in a separate kernel

  • LocalizedByRules

    Use rules as local variable lists

  • LookupCases

    Look up all values of a key in a nested association

  • MachineIntegerQ

    Check if a number falls into the range of machine-sized integers for your computer

  • MapBatched

    Divide a Map operation into batches, performing an evaluation between batches

  • MapCases

    Map a function at parts of an expression that match a given pattern

  • MapIf

    Map a function for elements in a list when a test gives True

  • MapSelectCounted

    Map a function over selected elements of a list, also passing in a running count of such elements

  • MessagedQ

    Test if a message is issued during an evaluation

  • MonitoredTestReport

    Generate a TestReportObject with dynamic progress

  • MonitorProgress

    Monitor the progress of a computation and display the current step and estimated time remaining

  • NotebookHistoryData

    Collect history of changes in the currently open notebooks

  • NumberParse

    Parse a string to a number safely

  • ObjectExistsQ

    Check if an object exists

  • OnceUnlessFailed

    Equivalent to using Once, but will only cache results if evaluation was successful

  • OnFailure

    Apply a function on an expression when FailureQ gives True on it; otherwise, return the expression

  • Pacletize

    Create a paclet layout from a collection of files, symbols and contexts

  • ParallelMapMonitored

    Run ParallelMap showing a progress monitor

  • PatternBindings

    Pick named elements of a pattern

  • PersistResourceFunction

    Install a resource function persistently so that it can be used like a built-in function

  • PlaceholderImage

    Create a placeholder image of a specified dimension

  • PossibleNameQ

    Test if an expression corresponds to a valid symbol name

  • PrefixQ

    Test if the first elements of a list are the same as those from another list

  • PrettyForm

    Print human-readable form of complex expressions

  • PrintAsCellObject

    Equivalent to Print, except returns a CellObject corresponding to the printed notebook cell

  • PrintDefinitionCases

    Find definitions for symbols in a context using a pattern, getting highlighted occurrences of it

  • PrintDefinitions

    Browse a list of hyperlinked definitions associated with a symbol

  • PrintMessage

    Print expressions to the messages window

  • ProcessorInformation

    Retrieve information on available processors

  • ProgressIndicatorEstimator

    Display progress of a computation together with estimated completion time

  • Proportions

    Get the proportion of times that each distinct element appears in a list

  • ProportionsBy

    Get the proportion of times that each distinct element appears in a list when evaluated with a given function

  • PythonPackageInstalledQ

    Test if the Python package can be accessed in your session

  • QueryTreeForm

    Present a query as a tree

  • QuietCheck

    Use Check and Quiet, conveniently combined into one function

  • RandomPartChoice

    Choose random parts of an expression

  • RealToHexString

    Give a string representing the hexadecimal form of a real number

  • ReapAssociation

    Equivalent to Reap, but returns an association with tags as keys

  • RecursiveRewrite

    Rewrite an expression replacing repeatedly by strings

  • RelativePath

    Create a file path relative to a given directory

  • ReplaceAllUnheld

    Apply replacement rules to evaluated parts of expression

  • ReplaceContext

    Transform an expression by replacing all symbols in one context with symbols of the same name in another context

  • ResetDataset

    Force a reanalysis of the types contained in a Dataset, sometimes leading to a different presentation of the data

  • ResetDirectoryStack

    Reset the value of Directory[] and DirectoryStack[]

  • ResourceFunctionDefinitionViewer

    View the definitions of a resource function along with its dependencies

  • ResourceFunctionMessage

    Print a labeled message from ResourceFunction with contexts hidden

  • ResourceFunctionSymbols

    Get a list of the symbols used in the definition of a resource function

  • RootSymbol

    Recursively take the head of an expression

  • RunAfterLoading

    Evaluate an expression when a package finishes loading

  • RunBeforeLoading

    Evaluate an expression when a package is first loaded

  • RunOnQuit

    Set an evaluation to run when the Wolfram Language kernel session is terminated

  • SameAsQ

    An operator form of SameQ

  • SaveAsString

    Quickly save an expression to a readable file

  • ScheduleCloudObjectExpiration

    Deploy a task to delete or replace a CloudObject after a delay

  • SearchMessages

    Search for a built-in message containing the given text

  • SearchOrderedList

    Search an ordered list at speed logarithmic in the length of a list

  • SecondsToQuantity

    Convert a number representing seconds to a quantity of time in an appropriate unit

  • SelectFirstIndex

    Find the index of the first element satisfying a criterion

  • SelectVersionNumber

    Choose a version number matching a specification

  • SerializeWithDefinitions

    Serialize an expression along with any needed definitions so that it can be used in another session

  • SessionInformation

    Get an association containing various session-related information

  • SetByRules

    Use rules to make assignments

  • SetOutputFormCellLabels

    Set up custom cell labels for a formatting function

  • SetTo

    Use as an operator form of Set

  • SetUnless

    Initialize a value unless it already satisfies a given condition

  • ShowQuotes

    Style the output so that quotation marks (as string characters) appear

  • SimplifyRepeatedSubexpressions

    Replace repeated subexpressions in an expression with new symbols

  • Slice

    An operator form of Part

  • StringPatternQ

    Test a valid string pattern

  • SuggestPlotRange

    Get a variable range against which to plot a given function

  • SwapSymbolValues

    Swap values of symbols using a temporary variable

  • SymbolCases

    Find symbols whose definition contains specified pattern

  • SymbolDependencies

    Get a list of symbols that an expression depends on

  • SymbolDependencyGraph

    Create a graph of symbol dependencies

  • SymbolsWithAttribute

    Find and list all symbols with a particular attribute

  • SymbolsWithOption

    Find and list all symbols with a particular option

  • ThrowFailure

    Throw a Failure object to the nearest enclosing CatchFailure

  • TimeMemoryUsed

    Return the time taken and the memory used by an operation

  • ToAssociations

    Recursively replace lists of rules with associations

  • ToFullString

    Create a string of the FullForm of an expression with fully qualified symbol names

  • TraceInteractive

    Trace an evaluation with an interface that allows interactive debugging

  • TraceLoading

    Monitor file-loading events during the evaluation of an expression

  • TracePrintEvaluations

    Print all expressions used in the evaluation of an expression, along with the results of evaluating those expressions

  • Uncurry

    Reverse a Curry operation

  • UnionTo

    Equivalent to Union but redefines the first argument to the result

  • UniqueContext

    Provide a new context that contains no symbols

  • Until

    Similar to While, but it performs the action before the test

  • Win32HotkeyHandlerClear

    Remove an existing hotkey handler

  • Win32HotkeyHandlerSet

    Set up system hotkey handlers

  • WithMessageHandler

    Apply a custom handler to messages generated during evaluation

  • WolframMark

    Run the standard Wolfram Language benchmark

  • WriteUnitTest

    Write a formatted and readable unit test for any input