Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2005
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

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

Search the Archive

Re: Output a list of keywords

  • To: mathgroup at smc.vnet.net
  • Subject: [mg63233] Re: Output a list of keywords
  • From: "Dr. Wolfgang Hintze" <weh at snafu.de>
  • Date: Tue, 20 Dec 2005 04:19:30 -0500 (EST)
  • References: <do67v4$aus$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Thank you, Bob.

With the slight modification replacing
{noms = Select[Names["*`*"],StringFreeQ[#, "`"]&]}
by
{noms = Select[Names["*`*"], StringPosition[#, "`"] == {} &]}
your Module works also for Version 4.

Wolfgang


Bob Hanlon wrote:

> This is close to what you asked for.
> 
> myFunction[x_]:=Sin[x]
> 
> (* The following should be the last cell in the notebook *)
> Module[{
>     noms=Select[Names["*`*"],StringFreeQ[#, "`"]&]},
>   Union[Cases[Drop[
>         NotebookGet[EvaluationNotebook[ ]][[1]],-1],
>       _?(MemberQ[noms, #]&),Infinity]]]
> 
> {Input,myFunction,Sin,x}
> 
> 
> Bob Hanlon
> 
> 
>>From: "Dr. Wolfgang Hintze" <weh at snafu.de>
To: mathgroup at smc.vnet.net
>>Date: 2005/12/17 Sat AM 03:46:19 EST
>>Subject: [mg63233]  Re: Output a list of keywords
>>
>>Interesting question. May I add a specific question which fits the 
>>topic: how do I get a list of the keywords used *directly* in my 
>>specific notebook?
>>
>>E.g. for the notebook containing only the following line
>>
>>myFunction[x_]:=Sin[x]
>>
>>the list should read
>>
>>myFunction
>>Sin
>>
>>This sometimes arises when I need to transform programs from one 
>>
> version 
> 
>>to the other and need to replace unknown functions.
>>
>>Thanks in advance.
>>
>>Regards,
>>Wolfgang
>>
>>Thomas Guignard wrote:
>>
>>
>>>Hi there
>>>
>>>Does anybody know of a way to output a list of all reserved keywords in 
>>>Mathematica (such as the listing in Section A.10 of the Mathematica 
>>>
> book)?
> 
>>>Thanks,
>>>Thomas
>>>
>>>
>>>
>>
> 


  • Prev by Date: Visualization site updates - string theory and photons
  • Next by Date: Re: Packages with Cyclic Dependencies
  • Previous by thread: Re: Re: Output a list of keywords
  • Next by thread: Re: Can I define 0^0 to be 1 for a notebook