PHP code example of vinkius-labs / markovable

1. Go to this page and download the library: Download vinkius-labs/markovable library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

vinkius-labs / markovable example snippets


use VinkiusLabs\Markovable\Facades\Markovable;

$baseline = 'analytics::predictive-saas';

Markovable::chain('analytics')
    ->cache($baseline)
    ->train($historicalSessions);

$insights = Markovable::predictive($baseline)
    ->dataset($latestTenantSnapshots)
    ->usingOptions([
        'churn' => ['

use VinkiusLabs\Markovable\Facades\Markovable;
use App\Markovable\SaaSAuthorityGraph;
use VinkiusLabs\Markovable\Models\PageRankSnapshot;

$authority = Markovable::pageRank()
    ->useGraphBuilder(new SaaSAuthorityGraph())
    ->dampingFactor(0.9)
    ->groupBy('prefix')
    ->