# Tag Info

## Hot answers tagged undocumented

46

The short answer is, yes! There is a whole undocumented package TemporalData containing some useful functions. The results below are from my own spelunking. Feel free to add/amend as appropriate. Let's set up some simple TemporalData objects to explore them: fakedata = Transpose@{DatePlus[{2001, 1}, {#, "Month"}] & /@ Range[0, 99], ...

44

LongestCommonSequencePositions and LongestCommonSubsequencePositions Their use is analogous to LongestCommon(Sub)sequence but they return the position of the first match instead. ClipboardNotebook[] can be used to access the clipboard. NotebookGet@ClipboardNotebook[] will give a Notebook expression with the current contents of the clipboard. I use this ...

44

One thing you can do is look for options which appear in a function's Options but do not have a ::usage message. Of course, some of the results actually are documented in the help, they just don't have a usage message. Here's a function to do it: undoc[x_Symbol]:=Select[Options[x],!StringQ@MessageName[Evaluate@First@#,"usage"]&]; undoc[_] = {}; (* e.g. ...

38

From inspection, some investigation and ruebenko's help, what I've found so far is that InterpolatingFunction has the following underlying structure: InterpolatingFunction[ domain, (* or min/max of grid for each dimension *) List[ version, (* 3 in Mathematica 7, 4 from 8 onwards *) ...

33

InternalInheritedBlock (IIB) is similar to Block, except that it preserves the original definition of the function being passed to it. The function can then be modified as we wish inside the IIB without affecting the external definition. Let's see how Block works first: f[x_] := x Block[{f}, Print@DownValues[f]; f[x_, y_] := x y; ...

33

Funny you should ask :), it turns out there is an undocumented use of Integrate that one can leverage to integrate over regions. Unfortunately this does not seem to work for NIntegrate. This usage is better leveraged in conjunction with some other undocumented functions (see here and here). I will show a few examples of how to use this feature. First, let's ...

31

The first element in the triples seems to indicate the type of curve used for the segment where 0 indicates a Line, 1 a BezierCurve, and 3 a BSplineCurve. I haven't figured out yet what 2 does. Edit: When the first element of the triple is 2, the segment will be a BezierCurve similar to option 1 except that with option 2, an extra control point is added to ...

27

1. Discovery may be aided by Trace and related tools. I recommend WReach's traceView functions. 2. Simple observation and experimentation. Simple does not imply easy. As an example, to find the answer to "Can the frame border on a BarChart Legend be removed?", I used: BarChart[{{1, 2, 3}}, ChartLegends -> {"A", "B", "C"}] // Trace // InputForm ...

26

I am somewhat reluctant to offer this as an answer since it is inherently difficult to comprehensively address questions on undocumented functionality. Nonetheless, the following observations do constitute partial answers to points raised in the question and are likely to be of value to anyone trying to write practical compiled code using Bags. However, ...

25

Other answers have already suggested ways of querying options. There's no way of systematically generating a list of all string values, but it's not too difficult to put together a list of all of the values which are used by Wolfram Research in Mathematica itself. If you look in the various files in these locations: ...

25

Thinking about a recent answer made me wonder exactly which functions in Mathematica use Assumptions. You can find the list of System functions that use that Option by running Reap[Do[Quiet[If[Options[Symbol[i], Assumptions]=!={}, Sow[i], Options::optnf]], {i, DeleteCases[Names["System*"], _?(StringMatchQ[#, "$"~~__] &)]}]][[2, 1]] which (can be ... 25 One of the excellent places to look is the Wolfram Demonstration Project. There are many cases with custom controls there. You can test out controls immediately and download the source code. Because I know that site pretty well I will keep the list here. Relief-Shaded Elevation Map 3D Waves Potter's Wheel Motion Blur Contours of Algebraic ... 23 One undocumented function I find useful is Precedence For example: {#, Precedence@#} & /@ {Plus, Minus, Times, Power, Apply, Map, Factor, Prefix, Postfix, Infix} // TableForm giving: Plus 310. Minus 480. Times 400. Power 590. Apply 620. Map 620. Factor 670. Prefix 640. Postfix 70. Infix 630. Precedence is described in a ... 23 There is the undocumented option Beveled in the FractionBox FractionBox[a, b, Beveled -> True] // DisplayForm 22 I find SetSystemOptions["PackedArrayOptions" -> {"UnpackMessage" -> True}] to be useful: it emits a message when a packed array is unpacked. This may happen automatically, sometimes slowing down things greatly. This is useful in situations like this or this. One way one would find out that such an option exists is "PackedArrayOptions" /. ... 22 nb2 = NotebookOpen @ FileNameJoin[ {$InstallationDirectory, "SystemFiles", "FrontEnd", "StyleSheets", "Core.nb"}]; Note that some of the named styles in the core stylesheet styles are empty, i.e. the style name is defined but no styles set: Cell[StyleData["style"]] For example (with V8): Union[Cases[NotebookGet[nb2],StyleData[x_, ___] :> x, ...

21

There is a public, but undocumented, function called GeometricFunctionsDecodeFilledCurve which helps to decode this type of undocumented FilledCurve: GeometricFunctionsDecodeFilledCurve[ FilledCurve[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{12.887695983062486, 5.160000000000004}, {1.8237311169604027, 5.160000000000004}, ...

21

InternalLocalizedBlock behaves the same as Block, but it can localize non-Symbols (e.g. f[1], Subscript[x, 0], etc.). For example, InternalLocalizedBlock[{Subscript[x, 0]}, Subscript[x, 0] = 1] (* 1 *) Compare this to Block[{Subscript[x, 0]}, Subscript[x, 0] = 1] (* During evaluation of In[79]:= Block::lvsym: Local variable specification ...

18

The two main arguments against using undocumented functions are: Your code might not work as expected in future versions; Your code might not work as you intended in the current version, because you only have a partial understanding of a function or option that is undocumented. In the case of Mathematica, though, there is no guarantee that even ...

17

Problems with undocumented functions I think that this is one of the things that everyone has to decide on their own. The biggest problem for using undocumented functions is that nobody is responsible for maintaining them, and therefore, it becomes explicitly your responsibility to maintain their use in the piece of software you are building with it. And ...

17

John Fultz posted an answer which had an undocumented option. CellPrint[{ Cell["Click to open the section", "Section", SystemWholeCellGroupOpener -> True], TextCell["Some text"]}] This produces a section cell that if you click anywhere on it will open and close the whole section.

15

I haven't looked deeper into this but have you tried all the events which you can find in the documentation of GUIKit? Especially here: GUIKit/ref/GUIInformation The list at the bottom contains at least all events you have mentioned: {"Action", "ActionPerformed", "Ancestor", "AncestorAdded", "AncestorMoved", "AncestorRemoved", "AncestorResized", ...

15

Some you can find in the Documentation Center, like the angular slider in Dynamic's documentation (under Applications), or the ValueThumbSlider in the Advanced Manipulate Functionality section (under Custom Control Appearances). Some you can find in developer packages like the angular slider in the "Experimental" package: Needs@"Experimental"; ...

15

This is not related to evaluation. InternalBag, like many other special types, is an atomic object. You can verify this using AtomQ[x]. This is despite its InputForm suggesting a structure. This is no different from how Graph, Rational, Complex or SparseArray behave. (Though for SparseArray, most list manipulation functions are implemented, so it's ...

15

It should be a comparison function. One can simulate the standard behavior by Signature[{1, 2, 3}, If[#1 < #2, True, 0] &] Signature[{2, 1, 3}, If[#1 < #2, True, 0] &] Signature[{1, 1, 3}, If[#1 < #2, True, 0] &] (* 1 *) (* -1 *) (* 0 *) If the first argument is less than the second we return True (or False, it doesn't matter!), ...

15

In addition to the error messages quoted in the question the line returns: GeneralUtilitiesBenchmarkingPackagePrivateplot[ IndexBy[{{{16, 9.37132*10^-6}, . . . IndexBy was removed from 10.1.0: Note that IndexBy will be removed in a future version of Mathematica. It was something that was considered for 10.0.0 but didn't make the cut. – Stefan R ...

14

I quite like SequenceLimit[] myself; it is a function that numerically estimates the limit of a sequence by applying the Shanks transformation (as embodied in Wynn's $\varepsilon$ algorithm). The method is a particularly nice generalization of the probably more well-known Aitken $\delta^2$ transformation for accelerating the convergence of a sequence. ...

14

Using FullForm, you can see that ImageSize -> 1 -> 1 is the same as ImageSize -> (1 -> 1) i.e., the option value itself is a rule. This appears to be an undocumented shorthand for scaling a graphics to the correct image size or to scale up/down by a factor. Observe the following, using a modified version of the example: img = ...

14

To create ExperimentalNumericalFunction, one needs to evaluate Experimental`CreateNumericalFunction[vars, expr, dims] where vars is a list of arguments, expr - the expression from which the numerical function will be created, dims - the dimensions of the output matrix produced by this expression. If the output is scalar, then dims should be set to {}. It ...

14

Introduction This post is long overdue as I have been repeatedly asked to explain code of mine containing these things. As I see increased use of this construct by others perhaps it is past due also. SparseArray objects can behave as functions accepting certain arguments to return internal data or efficiently return data in certain forms. These are known ...

Only top voted, non community-wiki answers of a minimum length are eligible