Skip to main content
Ctrl+K

Sciris

  • Overview
  • Tutorials
  • What’s new
  • Contributing
  • API reference
  • Web
  • GitHub
  • Overview
  • Tutorials
  • What’s new
  • Contributing
  • API reference
  • Web
  • GitHub

Section Navigation

  • Math and array tools
    • sc_math
      • approx
      • safedivide
      • findinds
      • findfirst
      • findlast
      • findnearest
      • count
      • dataindex
      • getvalidinds
      • getvaliddata
      • sanitize
      • rmnans
      • fillnans
      • findnans
      • nanequal
      • isprime
      • numdigits
      • perturb
      • normsum
      • normalize
      • inclusiverange
      • randround
      • cat
      • linregress
      • sem
      • rolling
      • convolve
      • smooth
      • smoothinterp
      • gauss1d
      • gauss2d
    • sc_asd
      • asd
  • Containers
    • sc_odict
      • ddict
      • odict
      • objdict
      • dictobj
      • asobj
    • sc_dataframe
      • dataframe
  • Files and versioning
    • sc_fileio
      • Blobject
      • Spreadsheet
      • Failed
      • load
      • save
      • loadobj
      • saveobj
      • zsave
      • loadstr
      • dumpstr
      • loadtext
      • savetext
      • loadzip
      • unzip
      • savezip
      • path
      • ispath
      • thisfile
      • thisdir
      • thispath
      • getfilelist
      • glob
      • getfilepaths
      • sanitizefilename
      • sanitizepath
      • makefilepath
      • makepath
      • rmpath
      • loadany
      • sanitizejson
      • jsonify
      • printjson
      • readjson
      • loadjson
      • savejson
      • readyaml
      • loadyaml
      • saveyaml
      • jsonpickle
      • jsonunpickle
      • loadspreadsheet
      • savespreadsheet
      • sciris.sc_fileio.UnpicklingWarning
      • sciris.sc_fileio.UnpicklingError
    • sc_versioning
      • freeze
      • require
      • gitinfo
      • compareversions
      • getcaller
      • metadata
      • loadmetadata
      • savearchive
      • loadarchive
  • Printing and plotting
    • sc_printing
      • prettyobj
      • quickobj
      • progressbars
      • capture
      • createcollist
      • objectid
      • classatt
      • objatt
      • objmeth
      • objprop
      • objrepr
      • prepr
      • pr
      • blank
      • indent
      • sigfig
      • sigfigs
      • sigfiground
      • arraymean
      • arraymedian
      • printmean
      • printmedian
      • humanize_bytes
      • printarr
      • printdata
      • printvars
      • colorize
      • heading
      • printred
      • printyellow
      • printgreen
      • printcyan
      • printblue
      • printmagenta
      • printv
      • slacknotification
      • printtologfile
      • percentcomplete
      • progressbar
    • sc_plotting
      • ScirisDateFormatter
      • animation
      • fig3d
      • ax3d
      • plot3d
      • scatter3d
      • surf3d
      • bar3d
      • stackedbar
      • boxoff
      • setaxislim
      • setxlim
      • setylim
      • commaticks
      • SIticks
      • getrowscols
      • get_rows_cols
      • figlayout
      • maximize
      • fonts
      • dateformatter
      • datenumformatter
      • savefig
      • savefigs
      • loadfig
      • emptyfig
      • separatelegend
      • orderlegend
      • savemovie
    • sc_colors
      • sanitizecolor
      • shifthue
      • rgb2hex
      • hex2rgb
      • rgb2hsv
      • hsv2rgb
      • vectocolor
      • arraycolors
      • gridcolors
      • midpointnorm
      • manualcolorbar
      • colormapdemo
      • alpinecolormap
      • bicolormap
      • parulacolormap
      • turbocolormap
      • bandedcolormap
      • orangebluecolormap
  • Parallelization and profiling
    • sc_parallel
      • Parallel
      • parallelize
    • sc_profiling
      • cprofile
      • tracecalls
      • resourcemonitor
      • checkmem
      • checkram
      • benchmark
      • cpu_count
      • cpuload
      • memload
      • loadbalancer
      • profile
      • mprofile
      • sciris.sc_profiling.LimitExceeded
  • Other utilities
    • sc_utils
      • autolist
      • Link
      • LazyModule
      • tryexcept
      • fast_uuid
      • uuid
      • dcp
      • cp
      • pp
      • sha
      • traceback
      • getuser
      • getplatform
      • iswindows
      • islinux
      • ismac
      • isjupyter
      • asciify
      • urlopen
      • wget
      • download
      • htmlify
      • flexstr
      • sanitizestr
      • isiterable
      • checktype
      • isnumber
      • isstring
      • isarray
      • isfunc
      • ismodule
      • toarray
      • tolist
      • promotetoarray
      • promotetolist
      • transposelist
      • swapdict
      • mergedicts
      • mergelists
      • ifelse
      • strjoin
      • newlinejoin
      • strsplit
      • runcommand
      • uniquename
      • suggest
      • importbyname
      • importbypath
      • sciris.sc_utils.KeyNotFoundError
      • sciris.sc_utils.LinkException
    • sc_datetime
      • timer
      • Timer
      • time
      • now
      • getdate
      • readdate
      • date
      • day
      • daydiff
      • daterange
      • datedelta
      • datetoyear
      • yeartodate
      • tic
      • toc
      • toctic
      • elapsedtimestr
      • timedsleep
      • randsleep
    • sc_nested
      • IterObj
      • Equal
      • getnested
      • setnested
      • makenested
      • iternested
      • iterobj
      • mergenested
      • flattendict
      • nestedloop
      • search
      • equal
    • sc_settings
      • ScirisOptions
      • parse_env
      • help
  • All modules
    • sciris
      • sc_asd
      • sc_colors
      • sc_dataframe
      • sc_datetime
      • sc_fileio
      • sc_math
      • sc_nested
      • sc_odict
      • sc_parallel
      • sc_plotting
      • sc_printing
      • sc_profiling
      • sc_settings
      • sc_utils
      • sc_version
      • sc_versioning
  • API reference
  • Other utilities
  • sc_utils
  • Link

Link#

class Link(obj=None)[source]#

Bases: object

A class to differentiate between an object and a link to an object. The idea is that this object is parsed differently from other objects – most notably, a recursive method (such as a pickle) would skip over Link objects, and then would fix them up after the other objects had been reinstated.

Version: 2017jan31

Methods

__call__(obj=None)[source]#

If called with no argument, return the stored object; if called with argument, update object

previous

autolist

next

LazyModule

On this page
  • Link
    • Link.__call__()

© Copyright 2014–2025 Sciris Development Team (version 3.2.1).

Built with the PyData Sphinx Theme 0.16.1.