Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
6d3768a
Update formhub.R
jmunene Feb 4, 2016
aa44647
Merge pull request #2 from jmunene/master
pld Feb 4, 2016
24f8f76
DW: added account param
denniswambua Feb 5, 2016
5ae9623
Merge pull request #3 from denniswambua/enable-org-accounts
pld Feb 19, 2016
c7416e3
PLD: update readme for new library name
pld Feb 19, 2016
4a504c6
PLD: point links to new repo
pld Feb 19, 2016
a607466
JM: rename to ona.R
jmunene Mar 30, 2016
1f5cf17
JM: Removed Formhub from Basics of Ona
jmunene Mar 30, 2016
9fa837b
JM: Removed Formhub from Basics of Ona
jmunene Mar 30, 2016
311e3a3
Replace formhub with ona
jmunene Mar 31, 2016
5a970f6
Replace formhub with ona
jmunene Mar 31, 2016
c12ad61
Replace formhub with ona in man folder files
jmunene Mar 31, 2016
8db8ad5
Rename file names with formhub to ona
jmunene Mar 31, 2016
4478b5e
Rename file names with formhub to ona
jmunene Mar 31, 2016
2831583
JM: Credits
jmunene Mar 31, 2016
6424967
Added testthat
jmunene Apr 6, 2016
d958499
Update testthat.R
jmunene Apr 6, 2016
2c5a0b9
AR|JM Modified tests for onaDownload function using testthat
Apr 6, 2016
3c6ce33
Add travis yml file
Apr 6, 2016
61f3b69
Update README.md
mberg Apr 10, 2016
4f42e0f
JM: Adding Tests
jmunene Apr 11, 2016
7746825
JM: Changing the test directory
jmunene Apr 11, 2016
a5ee9c8
AR Modified travis yml file
Apr 11, 2016
f48aa9c
JM: Deleted old test files
jmunene Apr 11, 2016
26bf787
JM: Changed test folder
jmunene Apr 11, 2016
ab9db09
JM: Changed test file
jmunene Apr 11, 2016
8a6137b
JM: Added install SP to the Travis file
jmunene Apr 12, 2016
c39e930
JM: Shortened lines
jmunene Apr 12, 2016
22f2fa9
JM: Added required packages to the yml file
jmunene Apr 12, 2016
19b2364
JM: Added testthat.R file
jmunene Apr 12, 2016
8edcca7
JM: Edited the main ona.R file to enable tests
jmunene Apr 14, 2016
7cb63ac
JM: Changed test directory
jmunene Apr 14, 2016
cafe613
JM: Changed the test directory url
jmunene Apr 14, 2016
57abca9
JM: Moved the fixtures folder to the testthat folder
jmunene Apr 14, 2016
3bc9a2d
JM: Commented on Ona read example
jmunene Apr 14, 2016
a04dd24
JM: Changed examples in onaread
jmunene Apr 14, 2016
584b330
JM: added warnings_are_errors:false on the travis file
jmunene Apr 14, 2016
1f3c1a4
Merge pull request #5 from onaio/replace_formhub_with_ona
pld Apr 15, 2016
80c80f0
Update README.md
jmunene Apr 15, 2016
916ac06
JM: Made changes after reviewing the merged package
jmunene Apr 15, 2016
8eb236e
Merge pull request #7 from onaio/review_changes
jmunene Apr 15, 2016
63052be
JM: Update link on readme
jmunene Jul 22, 2016
0d8e536
Merge pull request #12 from onaio/update_links
jmunene Jul 22, 2016
3e50fdd
Revert "JM: Update link on readme"
jmunene Jul 22, 2016
74ca92f
Merge pull request #13 from onaio/revert-12-update_links
jmunene Jul 22, 2016
489dbb9
PLD: add build status
pld Oct 4, 2016
15cccd4
JM: Updated suggests line for testthat
muneneg Aug 6, 2019
949cef6
JM: Edited examples in Ona.r file
muneneg Aug 6, 2019
5465631
JM: Changed the columns deletion test
muneneg Aug 6, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
warnings_are_errors: false
language: R
sudo: false
cache: packages
r_packages:
- devtools
- sp
- doBy
- lubridate
- plyr
- RCurl
- RJSONIO
- stringr
27 changes: 15 additions & 12 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
Package: formhub
Version: 0.0.3.9.3
Date: 2014-1-30
Title: formhub.R -- pulling data from formhub.org repositories easily.
Package: ona
Version: 0.0.1.1.1
Date: 2016-3-30
Title: ona.R -- pulling data from ona.io repositories easily.
Author: Prabhas Pokharel (Modi Research Group, Columbia University)
Maintainer: Prabhas Pokharel <[email protected]>
Clone: Jonathan Munene (Ona Kenya Ltd.)
Maintainer: Jonathan Munene <[email protected]>
Depends:
R (>= 2.15.1),
RJSONIO (>= 0.96),
Expand All @@ -14,13 +15,15 @@ Depends:
doBy,
sp
Suggests:
ggplot2
Description: formhub.R provides functions to pull data from formhub.org
into R. Included are functions to download the data directly from formhub,
read data from disk, and to convert formhub forms into dataframes.
formhub.R also parses data into the right formats according to the form
ggplot2,
testthat
Description: ona.R provides functions to pull data from ona.org
into R. Included are functions to download the data directly from ona,
read data from disk, and to convert ona forms into dataframes.
ona.R also parses data into the right formats according to the form
that was used to collect data, and offers some convenience functions
appropriate for data collected through surveys.
License: Dual-licensed. GPL for commercial uses. BSD for non-commercial uses.
URL: http://www.SEL-Columbia.github.com/formhub.R
BugReports: http://github.com/SEL-Columbia/formhub.R/issues
URL: https://github.com/onaio/ona.r
BugReports: https://github.com/onaio/ona.r/issues
RoxygenNote: 5.0.1
8 changes: 5 additions & 3 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
S3method(as.data.frame,formhubData)
# Generated by roxygen2: do not edit by hand

S3method(as.data.frame,onaData)
export(addPhotoURLs)
export(as.SpatialPointsDataFrame)
export(formhubDownload)
export(formhubRead)
export(onaDownload)
export(onaRead)
export(replaceAllNamesWithLabels)
export(replaceHeaderNamesWithLabels)
4 changes: 3 additions & 1 deletion NEWS
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
formhub.R News
ona.R News
Renaming formhub.R to ona.r (Mar 30, 2016):
*Renaming formhub.R to ona.r

Changes in formhub.R 0.0.3.9.3 (Jan 30, 2014):
* minor bugfix
Expand Down
196 changes: 89 additions & 107 deletions R/formhub.R → R/ona.R

Large diffs are not rendered by default.

40 changes: 21 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,43 @@
<link href="http://kevinburke.bitbucket.org/markdowncss/markdown.css" rel="stylesheet"></link>
formhub.R
=========
[![Build Status](https://travis-ci.org/onaio/ona.R.svg?branch=master)](https://travis-ci.org/onaio/ona.R)

formhub.R is a library for making reading data form [formhub.org](http://formhub.org) into R easier.
<a href="https://github.com/SEL-Columbia/formhub.R"><img style="position: absolute; top: 0; left: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_left_darkblue_121621.png" alt="Fork me on GitHub"></a>
ona.R
=====

ona.R is a library for making reading data form [ona.io](https://ona.io) into R easier.

This project is fork of [formhub.r](https://github.com/prabhasp/formhub.R) by Prabhas Pokharel. Future developments and improvements of the library will be done here.

Examples
--------

* Getting started -- [Basics of formhub.R](http://SEL-Columbia.github.com/formhub.R/demo/Basics_of_formhub.R.html)
* Quick example -- [Charting good_eats submission over time](http://SEL-Columbia.github.com/formhub.R/demo/Good_Eats_Example.html)
* Making maps -- [Making maps with North Ghana data](http://SEL-Columbia.github.com/formhub.R/demo/Water_Points_Example.html)
* Quality control -- [How long did it take to process a survey](http://SEL-Columbia.github.com/formhub.R/demo/How_Long_Example.html)
* Quality control II -- [A basic tutorial on removing outliers from your data](http://SEL-Columbia.github.com/formhub.R/demo/RemoveOutliers.html)
* Making Readable Data -- [Replacing "slugs" in data output with survey text](http://SEL-Columbia.github.io/formhub.R/demo/ReadableData.html)
* Getting started -- [Basics of ona.R](https://onaio.github.com/ona.R/demo/Basics_of_formhub.R.html)
* Quick example -- [Charting good_eats submission over time](https://onaio.github.com/ona.R/demo/Good_Eats_Example.html)
* Making maps -- [Making maps with North Ghana data](https://onaio.github.com/ona.R/demo/Water_Points_Example.html)
* Quality control -- [How long did it take to process a survey](https://onaio.github.com/ona.R/demo/How_Long_Example.html)
* Quality control II -- [A basic tutorial on removing outliers from your data](https://onaio.github.com/ona.R/demo/RemoveOutliers.html)
* Making Readable Data -- [Replacing "slugs" in data output with survey text](https://onaio.github.com/ona.R/demo/ReadableData.html)

For most of the examples, I use the [ggplot2](http://ggplot2.org) library, which is an amazing data visualization library worth every minute of your time spent learning it.

Installing formhub.R
Installing ona.R
--------------------
The package for formhub.R in R is simply called `formhub`. For now, it cannot be installed from CRAN, but using Hadley Wickam's excellent `devtools` package, you can install it directly from github. To install (or upgrade), run the following commands from your R terminal:
The package for ona.R in R is simply called `ona`. For now, it cannot be installed from CRAN, but using Hadley Wickam's excellent `devtools` package, you can install it directly from github. To install (or upgrade), run the following commands from your R terminal:

install.packages('devtools')
library(devtools)
install_github("formhub.R", username="SEL-Columbia")
library(formhub)
install_github("ona.R", username="onaio")
library(ona)

And voila! The `formhub` package is installed in your R system! You can check by running:
And voila! The `ona` package is installed in your R system! You can check by running:

help(formhubDownload)
help(onaDownload)

Features
--------

At the moment, it has the following features:

* One command download of formhub.org data -- both public and private
* One command download of [ona.io](https://ona.io/) data -- both public and private
* (Automatic) casting of data to the right type, based on the type of the input field in XLSform
* `select one` fields are converted to factors
* `integer`/`decimal` converted to numerics
Expand All @@ -44,6 +46,6 @@ At the moment, it has the following features:
* removeColumns convenience function that removes columns based on matching the title with a regular expression
* 'extra-schema' over-ride.

For planned features, go to the [issues](https://github.com/SEL-Columbia/formhub.R/issues) page.
For planned features, go to the [issues](https://onaio.github.com/ona.R/issues) page.


87 changes: 0 additions & 87 deletions demo/Basics_of_formhub.R.Rmd

This file was deleted.

Loading