jgr.addSubMenu | R Documentation |
adds a sub-menu to a Menu in JGR Console
jgr.addSubMenu(menu, subMenuName, labels, commands)
jgr.insertSubMenu(menu, subMenuName, labels, commands,index)
menu |
name of the menu to add this sub-menu to |
subMenuName |
name of the sub-menu |
labels |
a character vector of menu items |
commands |
a character vector of commands to be exectued |
index |
index at which to insert |
Menu
jgr.addMenu
jgr.addMenuItem
jgr.addMenu("added menu")
jgr.addMenuItem("added menu", "print 1","print(1)")
jgr.insertMenuItem("added menu","print 1 as if entered in console","print(1)",1,FALSE)
jgr.addMenuSeparator("added menu")
jgr.addSubMenu("added menu","sub menu",c("a","b","c"),c("print('a')","print('b')","print('c')"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.