0.0.3 • Published 4 years ago
pmath-plugin v0.0.3
import { Component } from '@angular/core';
import { Plugins } from '@capacitor/core';
import 'pmath-plugin';
const { PmathPlugin } = Plugins;
@Component({
selector: 'app-home',
templateUrl: 'home.page.html',
styleUrls: ['home.page.scss'],
})
export class HomePage {
results: any;
constructor() {
}
async gaussianCurveFitter() {
PmathPlugin.gaussianCurveFitter({value: JSON.stringify({x: [10, 20, 30], y: [10, 20, 30]})})
.then(result => {
console.log(result.value);
console.log(JSON.parse(result.value).length);
this.results = result;
});
}
}