rnseloader

Retrieve data from Reuters Newscope sentiment archive file

Syntax

x = rnseloader(file)
x = rnseloader(file, 'date', {DATE1})
x = rnseloader(file, 'date', {DATE1, DATE2})
x = rnseloader(file, 'security', {SECNAME})
x = rnseloader(file, 'start', STARTREC)
x = rnseloader(file, 'records', NUMRECORDS)
x = rnseloader(file, 'fieldnames', F)

Arguments

Specify the following arguments as name-value pairs. You can specify any combination of name-value pairs in a single call to rnseloader.

fileReuters® Newscope sentiment archive file from which to retrieve data.
'date'Use this argument with {DATE1, DATE2} to retrieve data between and including the specified dates. Specify the dates as numbers or strings.
'security'Use this argument to retrieve data for SECNAME, where SECNAME is a cell array containing a list of security identifiers for which to retrieve data.
'start'Use this argument to retrieve data beginning with the record STARTREC, where STARTREC is the record at which rnseloader begins to retrieve data. Specify STARTREC as a number.
'records'Use this argument to retrieve NUMRECORDS number of records.

Description

x = rnseloader(file) retrieves data from the Reuters Newscope sentiment archive file file, and stores it in the structure x.

x = rnseloader(file, 'date', {DATE1}) retrieves data from file with date stamps of value DATE1.

x = rnseloader(file, 'date', {DATE1, DATE2}) retrieves data from file with date stamps between DATE1 and DATE2.

x = rnseloader(file, 'security', {SECNAME}) retrieves data from file for the securities specified by SECNAME.

x = rnseloader(file, 'start', STARTREC) retrieves data from file beginning with the record specified by STARTREC.

x = rnseloader(file, 'records', NUMRECORDS) retrieves NUMRECORDS number of records from file.

x = rnseloader(file, 'fieldnames', F) retrieves only the specified fields, F, in the output structure.

Examples

Retrieve data from the file 'file.csv' with date stamps of '02/02/2007':

x = rnseloader('file.csv','date',{'02/02/2007'}) 

Retrieve data from 'file.csv' between and including '02/02/2007' and '02/03/2007':

 x = rnseloader('file.csv','date',{'02/02/2007',...
'02/03/2007'})

Retrieve data from 'file.csv' for the security 'XYZ.O':

 x = rnseloader('file.csv','security',{'XYZ.O'})

Retrieve the first 10000 records from 'file.csv':

 x = rnseloader('file.csv','records',10000)

Retrieve data from 'file.csv', starting at record 100000:

  x = rnseloader('file.csv','start',100000)

Retrieve up to 100000 records from 'file.csv', for the securities 'ABC.N' and 'XYZ.O', with date stamps between and including the dates '02/02/2007' and '02/03/2007':

x = rnseloader('file.csv','records',100000,...
               'date',{'02/02/2007','02/03/2007'},...
               'security',{'ABC.N','XYZ.O'})

Was this topic helpful?