NAME

Rserve::REXP::Complex - an R numeric vector

SYNOPSIS

use Rserve::REXP::Complex;
use Math::Complex ();

my $vec = Rserve::REXP::Complex->new([ 1, cplx(4, 2), 'foo', 42 ]);
print $vec->elements;

DESCRIPTION

An object of this class represents an R complex vector (CPLXSXP).

METHODS

Rserve::REXP:Complex inherits from Rserve::REXP::Vector, with the added restriction that its elements are complex numbers. Elements that are not numbers have value undef, as do elements with R value NA.

sexptype

SEXPTYPE of complex vectors is CPLXSXP.