write_mjy_data_file_c

	status.i4.v = write_mjy_data_file_c(file_name.i1a.r, header_data.s.r,
					    num_channels.i4.v,
					    channel_data.sa.r,
					    horz_increment.r8.v,
					    num_traces.i4.v,
					    pnts_per_trace.i4.v,
					    options.u4.v,
					    timestamps.u4a.r
					    [,chan_1_values.g.v]
					    [,chan_2_values.g.v]
					    [,chan_3_values.g.v]
					    [,chan_4_values.g.v])

	This routine writes data to an MJY format binary data file.

	file_name	null terminated ASCII file name (including path)
	header_data	file header data
			(structure of type MJY_FILE_WRITE_HEADER_DATA)
	num_channels	number of channel data structures
			(up to MJY_FILE_MAX_CHANNELS)
	channel_data	channel data
			(up to MJY_FILE_MAX_CHANNELS structures of type
			 MJY_FILE_WRITE_CHANNEL_DATA)
	horz_increment	horizontal point increment in nanoseconds
	num_traces	number of traces to write
	pnts_per_trace	number of points per trace
	options		file write options
			(MJY_FILE_OPT_NONE -> no options selected
					      (treat channel values as
					       single precision floats),
			 MJY_FILE_OPT_DOUBLE_VALUES -> treat channel values as
						       double precision floats)
	timestamps	trace timestamps
			(number of traces values)
	[chan_1_values]	channel 1 values
	[chan_2_values]	channel 2 values
	[chan_3_values]	channel 3 values
	[chan_4_values]	channel 4 values

	This function returns ACNET status values as follows:

	OK			success
	CLIB_INVARG		invalid number of channels, traces,
				points per trace, or value pointer
	CLIB_NOTOPN		failed to open the file

	This function requires the following include files:

	cnsparam_h, ul_cbsaux_h:auxlib_misc_h, acnet_errors_h

	Related functions:

	read_mjy_data_file_c

	C/C++ usage:

	static const char	file_name[] = "FB-20150310-cycle-1";
	int	status;
	int	num_channels = MJY_FILE_MAX_CHANNELS;
	int	num_traces = NUM_TRACES;
	int	pnts_per_trace = PNTS_PER_TRACE;
	unsigned int	options = MJY_FILE_OPT_DOUBLE_VALUES;
	unsigned int	timestamps[NUM_TRACES];
	double	horz_increment;
	double	chan_1_values[NUM_VALUES];
	double	chan_2_values[NUM_VALUES];
	double	chan_3_values[NUM_VALUES];
	double	chan_4_values[NUM_VALUES];
	MJY_FILE_WRITE_HEADER_DATA	header_data;
	MJY_FILE_WRITE_CHANNEL_DATA	channel_data[MJY_FILE_MAX_CHANNELS];

	status = write_mjy_data_file_c(file_name,&header_data,num_channels,
				       channel_data,horz_increment,num_traces,
				       pnts_per_trace,options,timestamps,
				       (void *) chan_1_values,
				       (void *) chan_2_values,
				       (void *) chan_3_values,
				       (void *) chan_4_values);