Wolfram Research

Function Repository Resource:

Bob

Source Notebook

Make anything bob up and down

Contributed by: Bob Sandheinrich

ResourceFunction["Bob"][expr]

displays a bobbing version of expr.

ResourceFunction["Bob"][expr,rate]

bobs at the specified rate.

ResourceFunction["Bob"][expr,rate,size]

bobs with the specified size.

Details and Options

The default rate and size are each 1.
ResourceFunction["Bob"] accepts the option UpdateInterval with a default value of 0.05.
The result of ResourceFunction["Bob"] is a ResourceFunction["Bob"] object.

Examples

Basic Examples

Bob something:

In[1]:=
ResourceFunction["Bob"]["Something"]
Out[1]=

Bob it fast and slow:

In[2]:=
{ResourceFunction["Bob"]["it", 5], ResourceFunction["Bob"]["it", 1/5]}
Out[2]=

Bob it big and small:

In[3]:=
{ResourceFunction["Bob"]["it", 1, 5], ResourceFunction["Bob"]["it", 1, 1/5]}
Out[3]=

Scope

Bob the callouts on a plot:

In[4]:=
ListPlot[Table[Callout[i, ResourceFunction["Bob"][i, 3]], {i, 1, 5}]]
Out[4]=

Bob one image next to another:

In[5]:=
Row[{First@WebImageSearch["Bird", "Thumbnails", MaxItems -> 1],
  ResourceFunction["Bob"]@
   First@WebImageSearch["Worm", "Thumbnails", MaxItems -> 1]}]
Out[5]=

This bird can really move its voice up and down:

In[6]:=
ResourceFunction["BirdSay"][ResourceFunction["Bob"]["Chirp Chirp"]]
Out[6]=

Options

Specify an UpdateInterval:

In[7]:=
Row[{"This is ", ResourceFunction["Bob"]["choppy", UpdateInterval -> .7], ResourceFunction["Bob"][" smooth", UpdateInterval -> 0.02]}]
Out[7]=

Properties and Relations

The result is a wrapped in Bob:

In[8]:=
InputForm[ResourceFunction["Bob"]["Hello world"]]
Out[8]=
In[9]:=
Head[%]
Out[9]=

As of version 12, there are only two top-level Wolfram Language symbols which are non-trivial palindromes:

In[10]:=
Select[Names["*"], PalindromeQ[#, IgnoreCase -> True] && StringLength[#] > 1 &]
Out[10]=

Bob joins their ranks from within the Function Repository:

In[11]:=
PalindromeQ[#, IgnoreCase -> True] && StringLength[#] > 1 &@ToString[
ResourceFunction["Bob"]]
Out[11]=

Neat Examples


I am Bob Sandheinrich, and so can you!

In[12]:=
ResourceFunction["Bob"]["Sandheinrich"]
Out[12]=

Resource History

See Also

License Information