https://github.com/apiko-dev/meteor-google-prediction
Google Prediction API v1.6 Meteor client
https://github.com/apiko-dev/meteor-google-prediction
google-prediction-api javascript meteor
Last synced: about 2 months ago
JSON representation
Google Prediction API v1.6 Meteor client
- Host: GitHub
- URL: https://github.com/apiko-dev/meteor-google-prediction
- Owner: apiko-dev
- License: mit
- Created: 2015-09-22T11:23:15.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-04-04T19:53:24.000Z (about 8 years ago)
- Last Synced: 2025-03-27T08:45:10.263Z (2 months ago)
- Topics: google-prediction-api, javascript, meteor
- Language: JavaScript
- Homepage: https://atmospherejs.com/jss/meteor-google-prediction
- Size: 12.7 KB
- Stars: 5
- Watchers: 15
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Google Prediction API Client
Google Prediction API v1.6 client for Meteor.
## Quick example
```js
//initialize client
var authOptions = {
serviceEmail: CloudSettings.SERVICE_EMAIL,
pemFile: CloudSettings.PEM_FILE, //PEM file name located in `/private` directory
projectName: 'MyProjectName' //name of your project in google developer console
};
var googlePrediction = new GooglePrediction(authOptions); //create new client instance//training new model
var insertResult = googlePrediction.insert("MyModel","GoogleCloudStorageBucketName","training-data-file.csv");//check model status
var modelStatus = googlePrediction.get("MyModel");//list available models
var models = googlePrediction.list();//make prediction
var inputData = [25,'foo',30,'bar'];
var result = googlePrediction.predict("MyModel", inputData);//access to prediction API
console.log('Predicted Value: ', result.outputValue);
```## Supported methods
* analyze
* delete
* get
* insert
* list
* predict
* updateAlso, see [full API Reference](https://cloud.google.com/prediction/docs/reference/v1.6/)
## Getting PEM file
This package is built on top of `google-oauth-jwt` npm package. Here's [detailed instruction](https://www.npmjs.com/package/google-oauth-jwt#creating-a-service-account-using-the-google-developers-console) how to generate `.pem` file.
-------------
Made by [](http://jssolutionsdev.com/?github=Databazel) - [Custom Software Development Company](http://jssolutionsdev.com/?github=Databazel)