Loading...
 
Skip to main content

History: r_test

Source of version: 96

Copy to clipboard
            ^
R_test seeks to be an easy way of testing PluginR ([http://dev.tiki.org/PluginR]) on advanced usage, where a basic pretty tracker workflow is needed for users to upload a file with data to be processed, and a page with a program in R language has to process it and produce some output for that user. 
{DIV(float="right")}{img src=http://www.r-project.org/Rlogo.jpg }{DIV}
There are a few __sets of tests__ for the time being:
* __Welcome to Plugin R__ page: tests if R & PluginR are installed successfully already.
* __Test1__. Testing simple R commands to test that the installation went fine
** Test output
** Simple graphical output
** Basic image with svg and pdf export
** Calling commands with admin validation (like install.packages, etc)
** Graphical output with advanced packages (like googleVis)
* __Test2__. Testing several other commands
** Tiki Dynamic variable usage
** Parsing html code
** Wikisyntax param
* __Test3__. Testing the process of working with datasets for a script to use them as parameters. The interface is organized in 4 tabas:
## Listing raw datasets
*** This first tab uses the standard output of [https://doc.tiki.org/PluginTrackerList|Plugin TrackerList] to display the data stored in the database of datasets  ("Tracker" or items, in Tiki terms).
## Showing the results after the dataset is run
*** This part uses a [https://doc.tiki.org/Pretty+Tracker|Pretty Tracker] with the (smarty) template in a wiki page, instead of just the standard output of [https://doc.tiki.org/PluginTrackerList|Plugin TrackerList] used in the first tab. Thus, the display is controlled by the (smarty) template "r_test3_template01", and it can be much more customized with the [https://doc.tiki.org/Wysiwyg|Wysiwyg] editor in Tiki.
## Dataset edition (provided that a dataset is selected in the first tab)
*** This third tab allows the user to edit the parameters for the graph generated by the R script, by means of using [https://doc.tiki.org/PluginTracker|Plugin Tracker] to preload a previous item when requested (itemId value must be assigned in the url).
## Inserting new datasets
*** This last tab allows to insert new items, by means of using [https://doc.tiki.org/PluginTracker|Plugin Tracker], despite the fact that the page has already loaded a previous item or not.
* __Test4__. Testing the production of a basic image with svg and pdf export. (in the future, extended with the help of other R packages)
* __Test5__. Testing some nice graphs from R. You might need some  extra packages for R:
** Word-cloud art
* __Test6__. Testing some nice interactive graphs
** Created through the googleVis package. You might need some  extra packages for R.
This menu will be created also: ((Profile_r_test_menupage))

__Requirements__:
* A Tiki site on a server :-). See [https://doc.tiki.org/Requirements|Requirements] and [https://doc.tiki.org/Installation|Installation] if needed. 
* [https://doc.tiki.org/PluginR|PluginR] , 
+ downloadable as a Mod from [http://mods.tiki.org/details.php?type=wikiplugins&mod=r|http://mods.tiki.org]
+ or installable as a mod from the tiki mods interface: tiki-mods.php
* [http://r-project.org|R project] installed in the same server as Tiki
* Understand how to apply a profile into your own Tiki site :-)
+ See the page ((Welcome to Tiki Profiles))
^

__New since August 2011__:
* See related profile ((R_HeatMaps)), as shown in:
+ http://ueb.vhir.org/User+2011

{maketoc}

These pages will be created:
~~lightgrey:''(listed properly only when shown here: http://profiles.tiki.org/r_test , not when you are at profile installation in your remote tiki site)''~~
{TITLESEARCH(search="r_test",exclude="r_test",noheader="1")}{TITLESEARCH}

!! Trackers

{CODE(caption=>YAML,wrap=>1)}
preferences:
 feature_trackers: y
 trackerfield_file: y
 trackerfield_files: y
 trackerfield_dropdownother: y
 feature_user_watches: y 
 feature_view_tpl: n
 feature_edit_templates: y
 feature_wiki_templates: y
 wikiplugin_r: y
 wikiplugin_rr: y
 feature_multilingual: y
 lang_use_db: y
instructions: Welcome to Plugin R
objects:
 -
  type: tracker
  ref: r_test_tracker1
  data:
   name: Datasets
   description: Files with data (like csv) to be processed by R scripts through tracker plugin calls
   default_status: open
   show: [ status, creation_date, modification_date, list_modification_date ]
   allow: [ comments, one_item_per_user, attachments ]
 -
  type: tracker_field
  ref: r_test_summary
  data:
   name: Summary
   tracker: $r_test_tracker1
   type: text_field
   flags: [ searchable, public, list, mandatory, link ]
   order: 10
 -
  type: tracker_field
  ref: r_test_description
  data:
   name: Description
   tracker: $r_test_tracker1
   type: text_area
   options: 1
   flags: [ public ]
   order: 20
 -
  type: tracker_field
  ref: r_test_from
  data:
   name: From user
   tracker: $r_test_tracker1
   type: user
   options: 1
   flags: [ searchable, public, list ]
   order: 30
 -
  type: tracker_field
  ref: r_test_attachment
  data:
   name: Dataset file
   tracker: $r_test_tracker1
   type: attachment
   flags: [ searchable, public, list ]
   order: 40
 -
  type: tracker_field
  ref: r_test_xmin
  data:
   name: Minimum value for axis X
   tracker: $r_test_tracker1
   type: text_field
   flags: [ searchable, public, list ]
   order: 50
 -
  type: tracker_field
  ref: r_test_xmax
  data:
   name: Maximum value for axis X
   tracker: $r_test_tracker1
   type: text_field
   flags: [ searchable, public, list ]
   order: 60
{CODE}

!! Groups & Permissions

{CODE(caption=>YAML, wrap=1)}
permissions:
 Anonymous:
  allow: view
  deny: [ ]
 Registered:
  description: Will be ignored because group is already created
  allow:
   - create_tracker_items
   - list_trackers
   - view_trackers
   - watch_trackers
  deny: [  ]
  objects:
   -
    type: wiki_page
    id: r_test3_template01
    allow: use_as_template
 Editors:
  description: Trusted users
  allow:
   - modify_tracker_items
   - trust_input
   - view_templates
   - edit_templates
   - use_content_templates
   - edit_content_templates
   - admin_content_templates
   - use_as_template
 Admins:
  description: Have all rights
  allow:
   - admin
   - trust_input
{CODE}

!! Users and group assignations

{CODE(caption=>YAML,wrap=>1)}
objects:
 -
  type: users
  data: 
    name: user
    pass: 1234
 -
  type: users
  data: 
    name: admin
    group: [ Editors ]
{CODE}

!! Sample data

{CODE(caption=>YAML,wrap=>1)}
objects:
 -
  type: tracker_item
  ref: dataset_001
  data:
   tracker: $r_test_tracker1
   status: open
   values:
    - [ $r_test_summary, Sample dataset ]
    - [ $r_test_from, admin ]
    - [ $r_test_description, "This dataset was created as part of the sample data for r_test." ]
    - [ $r_test_attachment, ]
    - [ $r_test_xmin, 1]
    - [ $r_test_xmax, 10]
 -
  type: tracker_item
  ref: dataset_002
  data:
   tracker: $r_test_tracker1
   status: pending
   values:
    - [ $r_test_summary, We are working on this dataset ]
    - [ $r_test_from, admin ]
    - [ $r_test_description, "This will soon be changed" ]
    - [ $r_test_attachment, ]
    - [ $r_test_xmin, 21]
    - [ $r_test_xmax, 30]
 -
  type: tracker_item
  ref: dataset_003
  data:
   tracker: $r_test_tracker1
   status: closed
   values:
    - [ $r_test_summary, A really old dataset ]
    - [ $r_test_from, admin ]
    - [ $r_test_description, "This dataset is outdated." ]
    - [ $r_test_attachment, ]
    - [ $r_test_xmin, 100]
    - [ $r_test_xmax, 110]

{CODE}

!! Modules
{CODE(caption=>YAML)}
objects:
 -
  type: module
  ref: module_last_modif_tracker_items
  data:
   name: last_modif_tracker_items
   groups: [ Anonymous, Registered ]
   position: right
   order: 5
   params:
    trackerId: $r_test_tracker1
    name: Summary
{CODE}


!! Wiki pages

{CODE(caption=>YAML)}
preferences:
  enable: [ feature_wiki ]
objects:
  -
    type: wiki_page
    ref:  r_test_instructions_page
    data:
      name: Welcome to Plugin R
      description: Basic intructions of PluginR and this profile
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test_instructions
  -
    type: wiki_page
    ref:  r_test1_page
    data:
      name: r_test1
      description: Interface to send datasets
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test1
  -
    type: wiki_page
    ref:  r_test2_page
    data:
      name: r_test2
      description: Interface to test several things
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test2
  -
    type: wiki_page
    ref:  r_test3_page
    data:
      name: r_test3
      description: Interface to change graph params and display png
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test3
  -
    type: wiki_page
    ref:  r_test3_template01_page
    data:
      name: r_test3_template01
      description: Template for wiki page
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test3_template01
  -
    type: wiki_page
    ref:  r_test4_page
    data:
      name: r_test4
      description: Interface to test security checks
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test4
  -
    type: wiki_page
    ref:  r_test5_page
    data:
      name: r_test5
      description: Some examples of neat Cloud-art graphs to dogfood Tiki information
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test5
  -
    type: wiki_page
    ref:  r_test6_page
    data:
      name: r_test6
      description: Some examples of neat usage of RGoogleVis package
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test6

{CODE}

!! Content Templates for pre-defined reports

{CODE(caption=>YAML,wrap="1")}
objects:
 -
  type: template
  ref: content_template_report_01
  data:
   name: Report 01
   content: wikicontent:Profile_r_test_ContentTemplate_Report_01
   sections: [ wiki ]
{CODE}

!! Useful navigational aid
!!! Wiki Page for the Menu
This will add the page ((Profile_r_test_menupage)) as the menu content

{CODE(caption=>YAML,wrap="1")}
objects:
  -
    type: wiki_page
    ref: r_test_menupage_include
    data:
      name: Menu for R tests
      description: Collaborative simple menu
      lang: en
      mode: create_or_update
      content: wikicontent:Profile_r_test_menupage
{CODE}

!!! Module wiki side menu
{CODE(caption=>YAML,wrap=>1)}
objects:
 -
  type: module
  ref: module_menupage
  data:
   name: menupage
   position: right
   groups: [ Anonymous, Registered ]
   order: 2
   params:
    pagemenu: Menu for R tests
{CODE}

!!! Extra features enabled for this profile
Add smileys for an easy way to add icons for bullets in the wiki page menu, without making them too much on the right. 
{CODE(caption=>YAML,wrap="1")}
preferences:
 feature_smileys: y
 feature_search_fulltext: y
 feature_wiki_argvariable: y
 feature_syntax_highlighter: y
 wiki_dynvar_style: double
 wikiplugin_div: y
 wikiplugin_group: y
 wikiplugin_iframe: y
 wikiplugin_img: y
 wikiplugin_pluginmanager: y
 wikiplugin_listpages: y
 wikiplugin_titlesearch: y
 wikiplugininline_div: y
 wikiplugininline_group: y
 wikiplugininline_iframe: y
 wikiplugininline_img: y
 wikiplugininline_fade: y
 wikiplugininline_remarksbox: y
 wikiplugininline_pluginmanager: y
 wikiplugininline_listpages: y
 wikiplugininline_titlesearch: y
{CODE}

-=Links=-
* [https://doc.tiki.org/PluginR]
* [https://dev.tiki.org/PluginR]
* [http://r-project.org]
* [http://mods.tiki.org/details.php?type=wikiplugins&mod=r]
        

History

Information Version
Fri 14 of Oct, 2016 09:17 GMT-0000 Xavi (as xavidp - admin) Mass search and replace 119
Wed 05 of Feb, 2014 04:44 GMT-0000 dirschneid Image Plugin modified by editor. 118
Fri 31 of Jan, 2014 18:57 GMT-0000 Xavi (as xavidp - admin) added r_test12_ecoengine 117
Fri 31 of Jan, 2014 10:38 GMT-0000 Xavier de Pedro remove users 116
Sun 19 of Jan, 2014 12:09 GMT-0000 Xavier de Pedro updated test names and added desc for test11 115
Sun 19 of Jan, 2014 12:04 GMT-0000 Xavier de Pedro added Profile_r_test11_animation 114
Tue 07 of Jan, 2014 14:17 GMT-0000 Xavier de Pedro improved page title also in profiles.t.o 113
Tue 07 of Jan, 2014 14:04 GMT-0000 Xavier de Pedro wikiplugin_aname added since it's used in some wiki page 112
Tue 07 of Jan, 2014 13:56 GMT-0000 Xavier de Pedro fixed the name of 512paths to avoid issues with <strong> tags in some rare cases 111
Tue 07 of Jan, 2014 13:50 GMT-0000 Xavier de Pedro renamed pages to include two digits in the numbering 110
Tue 07 of Jan, 2014 13:27 GMT-0000 Xavier de Pedro added r_test_10_clickme 109
Mon 23 of Dec, 2013 17:18 GMT-0000 Xavier de Pedro added feature_jquery_media 108
Thu 19 of Dec, 2013 11:30 GMT-0000 Xavier de Pedro updated with 512paths as test9 subpage and r_test7 showing a plot.ly test 107
Wed 18 of Dec, 2013 14:36 GMT-0000 Xavier de Pedro updated info 106
Tue 17 of Dec, 2013 17:13 GMT-0000 Xavier de Pedro added the new r_test9_charts pages 105
Tue 17 of Dec, 2013 16:58 GMT-0000 Xavier de Pedro added r_test9 104
Fri 18 of Oct, 2013 10:05 GMT-0000 Xavier de Pedro layout and typo 103
Fri 18 of Oct, 2013 10:04 GMT-0000 Xavier de Pedro added test8. thks jyhem and joël 102
Sat 31 of Aug, 2013 08:02 GMT-0000 Xavier de Pedro updated 101
Tue 11 of Jun, 2013 07:53 GMT-0000 Xavier de Pedro stop changing sefurl in the local tiki site to prevent issues in sites where no htaccess nor rewrite rules has been enabled 100
Fri 31 of May, 2013 10:02 GMT-0000 Xavier de Pedro tweaks 99
Sat 25 of May, 2013 14:44 GMT-0000 Xavier de Pedro added sef feature for r_test3 98
Fri 10 of May, 2013 15:25 GMT-0000 Xavier de Pedro added r_test7 97
Thu 09 of May, 2013 10:06 GMT-0000 Xavier de Pedro updated to sync current tests 96
Thu 15 of Nov, 2012 01:00 GMT-0000 Xavier de Pedro typo 95