Category Archives: R

Knitr with Bio7

16.04.2015

In Bio7 it is possible to write a documentation in knitr. A simple visual and textual HTML editor (based on JavaFX) and an embedded Latex editor (based on TeXclipse) helps in the creation of a *.html or *.pdf documentation. For the *.pdf creation a TeX environment has to be available (Windows e.g. MiKTeX).

Overview video:

Note that there is still a bug in the visual JavaFX HTML editor (JavaFX SWT bug) to select text in the visual part of the editor. A workaround is to use the combination of Shift- or Ctrl-key and a mouse-click.

In upcoming releases more improvements for R reports will be available in Bio7.

 

Bio7 2.0 for Windows 32 bit Release

24.03.2015

Because of some requests of a Windows 32 bit version of Bio7 2.0 I uploaded a built to sourceforge.

Release notes:

  • Updated R to version 3.1.3
  • Updated ImageJ to version 1.49p
  • Added some ImageJ dialog options (to stay on top, e.g., the ROI Manager)
  • Updated Java to version 1.8.40
  • Updated the JavaFX embedded SceneBuilder to Java 1.8.40

If you don’t know Bio7 here is an overview of the features (not only R):

Bio7 can be downloaded here:

http://bio7.org

Documentation and Videos Tutorials:

Documentation

Video Tutorials YouTube

 

 

Bio7 2.0 for Linux Released!

01.02.2015

I released the Linux version of Bio7 2.0 (see screenshot below).

screenlinux

For an overview of the new Bio7 features follow the link: Bio7 2.0 new features

Added Linux features:

  • A new Java menu action (in the Scripts menu) is available to start a Py4J server which can communicate to Java and CPython (if enabled in the native preferences of Bio7 and Py4J is installed in the local Python distribution). With this feature it is, e.g., possible to transfer ImageJ values to CPython or call the Bio7 Java API.
  • Improved the embedded native pseudo terminal to send signals to a process tree (e.g., SIGINT = STRG+C).
  • Added an option in the native preferences to interpret a Python script with a a native CPython interpreter >=3.0.

Installation:

Download Bio7 and simply unzip the Bio7 archive file in your preferred location. Bio7 comes bundled with a JRE so you don’t need to install Java separately. The Bio7 application was tested on Ubuntu 14.04 (minimum requirement).

R features:

For the Linux version of Bio7 2.0 R and Rserve have to be installed. For the use in Bio7 Rserve has to be compiled with a special flag to enable the cooperative mode (see below).

In a shell simply execute:

sudo PKG_CPPFLAGS=-DCOOPERATIVE R CMD INSTALL Rserve_1.8-1.tar.gz

The command will compile and install the Rserve package in your default Linux R application. This is necessary to share the R workspace when you switch from a local Rserve connection to the native Bio7 R console (see this video for an explanation of the new connection mode in Bio7).

Please note that the default R package location of Bio7 is: /usr/lib/R/site-library

The location (and the path to R) can be changed in the R preferences of Bio7 (e.g., menu: R->Preferences).

 

 

 

 

 

 

 

Image Data Transfer to R with ImageJ and Bio7 2.0

09.12.2014

In the new version of Bio7 2.0 i added some new easy to use functions to transfer image data from ImageJ to R. For example, you can now drag a folder of images on the ImageJ-Canvas
view, open them memory efficient as a virtual stack in ImageJ and transfer them with one action as a list (or raster stack) to R.

With the new or improved actions it is possible to:

  • Transfer an ImageJ stack or virtual stack to R (RGB data or selected datatype will be transferred as a list).
  • Optionally transfer the stack as a raster stack (if the “raster” package is installed).
  • Transfer measured “Particles”  values from the “Results Table” from ImageJ to R.
  • Transfer values from an opened ImageJ “Results Table”.

Video:

Beside this new or improved actions there are many other methods available to transfer image data, selected pixel or selected coordinate data from ImageJ to R.

For an overview of the different functions i created a video playlist on YouTube how Bio7 can effectively asssist in the transfer and statistical analysis of image data (with the help of ImageJ and R).

Playlist: