Available Applications

Physical Activity CoDa Regression Model

Investigate association between physical activity composition and a heath outcome directly (and obtain dose-response).


Physical Activity CoDa MANOVA

Categorise individuals by outcome and investigate how the categories differ in terms of the composition of physical activity.


Physical Activity CoDa Regression Model

This is our own tool developed in RStudio and made available through Shiny. It allows users to carry out standard linear regression analysis with compositional explanatory variables (and other standard covariates). The tool has been released recently, and is in an early stage of development, but feel free to give it a go, and let us know if you experience any problems.

We have a number of new features we would like to add to the tool time permitting (in particular producing ternary plots and modelling the results of isotemporal substitution on the overall population) in addition to improving the UI, but please let us know if you have any other suggestions.

The tool is freely available and we hope it is valuable to researchers in physical activity. Unfortunately we do not have the time and resources to provide full product support, or to carry out exhaustive product testing, and at this stage of development it is used on an "own-risk" basis. Nevertheless, we believe it will be a useful exploratory tool, and could provide an independent check on your own work.

( https://opencoda.shinyapps.io/physical_activity_coda_regression_model/ )

Take me to the App

Brief Guidance on using PACRM


  1. Data must be uploaded in .csv format. Any "data cleaning" should be done outside of the tool. 
  2. In particular, the tool may not recognize all "n/a" indicators. We recommend such fields be left as blanks, or the records omitted entirely.
  3. Once the data is uploaded it will display on the right hand side of the screen. Depending on the size of your data it may be necessary to scroll right to see all of the fields.
  4. If you just want to try out the tool without using your own data there is a simple dummy dataset below.


  1. The next stage is to identify the response variable / outcome in your data, the standard covariates / confounding variables you would like to include, and last (but not least) the compositional variables in your data.
  2. You will need to indicate continuous and categorical variables separately.


  1. The tool includes some limited functionality for selecting covariates for inclusion (AIC, and likelihood ratio tests on the effect of dropping individual variables) displayed on the second tab.
  2. Changing the selected covariates will cause these calculations to update automatically.


  1. Once you have identified the compositional variables, and given the tool a little time to compute, it will provide a list of the available transformed CoDa variables for carrying out the regression.
  2. These are calculated using the "robcompositions" package in R.
  3. We have used a similar naming convention to robcompositions:
    "_" indicates division, "." indicates geometric averaging, so for example "SB_MV.LI" would indicate the ilr coordinate is based on the logratio between "SB", and the geometric average of "MV" and "LI." The original variable names are often abbreviated in the ilr coordinate names.
  4. Currently the tool has been built to handle 3 or 4 components. In addition, the list of ilr coordinates for 4 components is restricted to those built on the pivot coordinate approach. We hope to expand the functionality to higher dimensions, and a more general set of balances, in the near future.
  5. The ilr coordinates for individual members are shown on the "ilr coordinates" tab.
  6. The results of the full regression analysis, including covariates are shown on the final tab.
  7. The analysis is fuller than the stage one model selection, but for many cases more testing may be advisable.


  1. It is straightforward to switch between different rotations, or indeed omit components entirely (which can be a valuable method for better understanding what is driving a response). 
  2. The calculations will update automatically each time the ilr coordinates are changed.

Data Security / Privacy

Users will need to give consideration to the ethical issues associated with uploading their data before using these applications, and the appropriateness of additional anonymisation. We do not actively collect data uploaded onto the applications, however we are not able to give guarantees as to the duration that uploaded data will be held by our hosting service. 

We're happy to provide users interested in using these tools with concerns about uploading their data with the means to run these tools on a private server. Please contact us if this would be of interest.

The applications are hosted on shinyapps.io. The information below is taken from their user guide.

"Each app is deployed into its own container, and the network access between containers is tightly controlled. All access to the apps is over SSL....

...The design of the system is for every account to have its own sub-directory structure, and to enforce the security at the file system and operating system levels. The storage for each container is not permanent, so if you need to store data, our strong recommendation is for you to push that data into your own data store. That could be a database such as Amazon’s RDS, or it could be on a file system accessible from within your application.

shinyapps.io is currently hosted on Amazon’s Web Services (AWS) infrastructure in the us-east-1 region. The infrastructure used is not the HIPAA-compliant stack, so if you need to be in a HIPAA-compliant environment, we recommend deploying and operating your own Shiny Server or Shiny Server Professional instance."

Find out more

Example Data for PACRM