Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Keeping track of variables used in Mathematica

  • To: mathgroup at smc.vnet.net
  • Subject: [mg122831] Re: Keeping track of variables used in Mathematica
  • From: Armand Tamzarian <mike.honeychurch at gmail.com>
  • Date: Fri, 11 Nov 2011 04:58:20 -0500 (EST)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • References: <j9ge4n$opm$1@smc.vnet.net>

On Nov 10, 10:56 pm, Mark <big.d... at att.net> wrote:
> Hello community:
>
> Does Mathematica have a command that will output or compute a list of cus=
tom variables assigned and used in a current notebook / Mathematica session=
?
>
> If so, what is the command / expression?
> Thanks in advance
> Mark

This

Names["Global`*"]

will give you a list of all global variables defined in your session.
If you have created variables in a different context you would have to
sub that context in the expression. The fact that a variable has been
defined doesn't mean that it is being used though. If getting a list
of variables *used* within your notebook is really what you want then
you could take the global list and scan your notebook using e.g. Cases
but I'll leave that for now.

Mike



  • Prev by Date: Re: Converting a list of strings to a single space-delimited string
  • Next by Date: How to specify the data-range with Import
  • Previous by thread: Re: Keeping track of variables used in Mathematica
  • Next by thread: Re: Keeping track of variables used in Mathematica