Builtins Reference

BioLang ships with 750+ built-in functions spanning bioinformatics, statistics, data wrangling, visualization, and systems programming. Every function is available without imports — just call it.

Showing all 750+ builtins

Name Category Signature Description
printCoreprint(values...) -> nilPrint values to stdout without newline
printlnCoreprintln(values...) -> nilPrint values to stdout with newline
lenCorelen(value) -> intReturn length of string, list, or map
typeCoretype(value) -> stringReturn type name as string
rangeCorerange(start, end, step?) -> listGenerate integer sequence
absCoreabs(n) -> numberAbsolute value
minCoremin(a, b) -> numberReturn smaller of two values
maxCoremax(a, b) -> numberReturn larger of two values
intCoreint(value) -> intCast to integer
floatCorefloat(value) -> floatCast to float
strCorestr(value) -> stringCast to string
boolCorebool(value) -> boolCast to boolean
assertCoreassert(cond, msg?) -> nilAssert condition is truthy or abort
debugCoredebug(value) -> valuePrint debug representation, return value
typeofCoretypeof(value) -> stringAlias for type()
is_nilCoreis_nil(value) -> boolCheck if value is nil
to_stringCoreto_string(value) -> stringConvert any value to its string representation
mapCollectionsmap(list, fn) -> listApply function to each element
filterCollectionsfilter(list, fn) -> listKeep elements where fn returns true
reduceCollectionsreduce(list, fn, init?) -> valueAccumulate list into single value
sortCollectionssort(list) -> listSort in ascending order
sort_byCollectionssort_by(list, fn) -> listSort with custom comparator
pushCollectionspush(list, value) -> listAppend element to end of list
popCollectionspop(list) -> valueRemove and return last element
shiftCollectionsshift(list) -> valueRemove and return first element
zipCollectionszip(a, b) -> listPair elements from two lists
enumerateCollectionsenumerate(list) -> listPair each element with its index
flattenCollectionsflatten(list) -> listFlatten nested lists one level
reverseCollectionsreverse(list) -> listReverse element order
uniqueCollectionsunique(list) -> listRemove duplicate elements
firstCollectionsfirst(list) -> valueReturn first element
lastCollectionslast(list) -> valueReturn last element
takeCollectionstake(list, n) -> listTake first n elements
dropCollectionsdrop(list, n) -> listDrop first n elements
anyCollectionsany(list, fn) -> boolTrue if any element matches predicate
allCollectionsall(list, fn) -> boolTrue if all elements match predicate
findCollectionsfind(list, fn) -> value|nilFind first matching element
find_indexCollectionsfind_index(list, fn) -> int|nilFind index of first match
chunkCollectionschunk(list, size) -> listSplit list into chunks of given size
window_slideCollectionswindow_slide(list, size) -> listSliding window over list
group_byCollectionsgroup_by(list, fn) -> mapGroup elements by key function
meanMathmean(list) -> floatArithmetic mean
medianMathmedian(list) -> floatMiddle value of sorted list
stdevMathstdev(list) -> floatStandard deviation (sample)
varianceMathvariance(list) -> floatVariance (sample)
sumMathsum(list) -> numberSum of all elements
quantileMathquantile(list, q) -> floatQ-th quantile (0.0 to 1.0)
ttestMathttest(a, b) -> mapTwo-sample t-test
correlationMathcorrelation(a, b) -> floatPearson correlation coefficient
sqrtMathsqrt(n) -> floatSquare root
logMathlog(n) -> floatNatural logarithm
randomMathrandom() -> floatRandom float in [0, 1)
upperStringupper(s) -> stringConvert to uppercase
lowerStringlower(s) -> stringConvert to lowercase
splitStringsplit(s, delim) -> listSplit string by delimiter
joinStringjoin(list, sep) -> stringJoin list elements into string
replaceStringreplace(s, old, new) -> stringReplace all occurrences
containsStringcontains(s, sub) -> boolCheck if string contains substring
formatStringformat(template, args...) -> stringFormat string with placeholders
tableTablestable(columns) -> tableCreate table from column map
csvTablescsv(path, opts?) -> tableRead CSV file into table
selectTablesselect(tbl, cols...) -> tableSelect columns from table
mutateTablesmutate(tbl, name, fn) -> tableAdd or modify column
left_joinTablesleft_join(a, b, on) -> tableLeft join two tables
pivot_widerTablespivot_wider(tbl, names, vals) -> tablePivot from long to wide format
matrixMatrixmatrix(rows) -> matrixCreate matrix from nested lists
matmulMatrixmatmul(a, b) -> matrixMatrix multiplication
pcaMatrixpca(mat, n_components) -> mapPrincipal Component Analysis
sparse_matrixSparsesparse_matrix(entries, r, c) -> sparseCreate sparse matrix from triplets
log1p_cpmSparselog1p_cpm(mat) -> sparselog(1 + CPM) normalization for scRNA-seq
regex_matchRegexregex_match(s, pattern) -> boolTest if pattern matches string
regex_capturesRegexregex_captures(s, pattern) -> listExtract capture groups
json_parseJSONjson_parse(s) -> valueParse JSON string
json_keysJSONjson_keys(value) -> listGet keys from a JSON object
nowDateTimenow() -> datetimeCurrent date and time
date_diffDateTimedate_diff(a, b, unit) -> intDifference between two dates
verify_checksumHashverify_checksum(path, expected, algorithm?) -> boolVerify file checksum (MD5, SHA-1, SHA-256)
sketchHashsketch(sequence, k, sketch_size) -> listMinHash sketch for sequence similarity
read_textFilesystemread_text(path) -> stringRead file contents as string
globFilesystemglob(pattern) -> listFind files matching glob pattern
http_getHTTPhttp_get(url, opts?) -> responseHTTP GET request
bio_fetchHTTPbio_fetch(db, id) -> mapFetch record from biological database
sparklineVizsparkline(data) -> stringUnicode sparkline chart
boxplotVizboxplot(data, opts?) -> stringASCII boxplot
plotPlottingplot(data, opts?) -> svgGeneric plot dispatcher
heatmapPlottingheatmap(mat, opts?) -> svgHeatmap from matrix data
volcanoPlottingvolcano(tbl, opts?) -> svgVolcano plot for DE analysis
manhattanBio Plotsmanhattan(tbl, opts?) -> svgManhattan plot for GWAS
circosBio Plotscircos(tracks, opts?) -> svgCircos plot for genomic data
cell_embeddingBio Plotscell_embedding(coords, labels) -> svgUMAP/tSNE cell embedding plot
container_runContainerscontainer_run(image, cmd, opts?) -> mapRun command in container
biocontainerContainersbiocontainer(tool, cmd) -> mapRun BioContainers tool
chatLLMchat(prompt, opts?) -> stringSend prompt to LLM
llm_modelsLLMllm_models() -> listList available LLM models
s3_downloadTransfers3_download(bucket, key, path) -> stringDownload from S3
sra_fastqTransfersra_fastq(accession, outdir) -> listDownload FASTQ from SRA
par_mapAdvancedpar_map(list, fn, threads?) -> listParallel map across threads
provenanceAdvancedprovenance(value) -> mapGet data provenance/lineage

Browse by Category

New in recent releases: additional sequence utilities, expanded sparse matrix ops, and new bio plot types bring the total to 750+ functions. Check the individual category pages for the latest additions.