function complex( x, mask, values ) {
	var mdata;
	var mget;
	var iv;
	var N;
	var i;

	mdata = mask.data;
	mget = mask.accessors[ 0 ];

	N = values.length;
	iv = 0;
	for ( i = 0; i < x.length; i += 2 ) {
		if ( !mget( mdata, i/2 ) ) {
			x[ i ] = values[ iv ];
			x[ i+1 ] = values[ iv+1 ];
			iv = ( iv+2 ) % N;
		}
	}
	return x;
}
Replaces elements in a complex array with provided values.

@private
@param {Collection} x - real-valued floating-point input array view
@param {Object} mask - mask array object
@param {Collection} values - real-valued floating-point values array view
@returns {Collection} input array view

@example
var Float64Array = require( '@stdlib/array/float64' );
var arraylike2object = require( '@stdlib/array/base/arraylike2object' );

var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] );

var mask = [ 0, 1, 0, 1 ];
var values = new Float64Array( [ 10.0, 20.0, 50.0, 60.0 ] );

var out = complex( x, arraylike2object( mask ), values );
// returns <Float64Array>[ 10.0, 20.0, 3.0, 4.0, 50.0, 60.0, 7.0, 8.0 ]