Problem

NAME

Algorithm::LibSVM::Problem - A Raku Algorithm::LibSVM::Problem class

SYNOPSIS

use Algorithm::LibSVM::Problem;

DESCRIPTION

Algorithm::LibSVM::Problem is a Raku Algorithm::LibSVM::Problem class

METHODS

l

Defined as:

method l return(--> Int:D)

Returns the number of the training data.

y

Defined as:

method y(--> List)

Returns the array containing the target values (Int values in classification, Num values in regression) of the training data.

x

Defined as:

method x(--> List)

Returns the array of pointers, each of which points to a sparse representation (i.e. array of Algorithm::LibSVM::Node) of one training vector.

nr-feature

Defined as:

method nr-feature(--> Int)

Returns the number of features.

from-matrix

Defined as:

method from-matrix(::?CLASS:U: @x where { $_.shape ~~ ($,$) }, @y --> Algorithm::LibSVM::Problem)

Creates a Algorithm::LibSVM::Problem instance. Where @x is the 2-dimensional shaped matrix for features, @y is the 1-dimensional array for labels.

from-kernel-matrix

Defined as:

method from-kernel-matrix(::?CLASS:U: @x where { $_.shape ~~ ($,$) }, @y --> Algorithm::LibSVM::Problem)

Creates a Algorithm::LibSVM::Problem instance. Where @x is the 2-dimensional shaped kernel matrix, @y is the 1-dimensional array for labels.

from-file

Defined as:

method from-file(::?CLASS:U: Str $filename --> Algorithm::LibSVM::Problem)

Creates a Algorithm::LibSVM::Problem instance. Where <$filename> is the filename of the libsvm format file.

AUTHOR

titsuki <[email protected]>

COPYRIGHT AND LICENSE

Copyright 2016 titsuki

This library is free software; you can redistribute it and/or modify it under the terms of the MIT License.

libsvm ( https://github.com/cjlin1/libsvm ) by Chih-Chung Chang and Chih-Jen Lin is licensed under the BSD 3-Clause License.

Algorithm::LibSVM v0.0.16

A Raku bindings for libsvm

Authors

  • titsuki

License

MIT

Dependencies

Test Dependencies

Provides

  • Algorithm::LibSVM
  • Algorithm::LibSVM::Actions
  • Algorithm::LibSVM::CustomBuilder
  • Algorithm::LibSVM::Grammar
  • Algorithm::LibSVM::Model
  • Algorithm::LibSVM::Node
  • Algorithm::LibSVM::Parameter
  • Algorithm::LibSVM::Problem

Documentation

The Camelia image is copyright 2009 by Larry Wall. "Raku" is trademark of the Yet Another Society. All rights reserved.