Search found 202 matches

by CharlieEVIEWS
Thu Sep 10, 2015 10:27 am
Forum: Data Manipulation
Topic: how to calculte the number of different obs in a series
Replies: 9
Views: 4981

Re: how to calculte the number of different obs in a series

Lot of views on this thread so I thought I'd post:

Code: Select all

freeze(seriesfreq) myseries.freq
scalar numberunique = @val(@mid(seriesfreq(5,1),22))


Should do the trick. Works for alphas too.
by CharlieEVIEWS
Tue Sep 08, 2015 10:32 am
Forum: Suggestions and Requests
Topic: autosave .prg on execute
Replies: 2
Views: 2082

autosave .prg on execute

I would find it useful if EViews would automatically commit changes when prgs are executed following edits through the IDE. I think there's probably an argument as to why it hasnt been done however.... just cant think of what it might be.

Charlie
by CharlieEVIEWS
Fri Sep 04, 2015 10:57 am
Forum: Programming
Topic: Graphs: Adding a line in a scatter plot
Replies: 9
Views: 3082

Re: Graphs: Adding a line in a scatter plot

Code: Select all

wfcreate u 100
genr x = nrnd
genr y = nrnd
group myscat x y
freeze(myscat_graph) myscat.scat linefit
by CharlieEVIEWS
Thu Sep 03, 2015 11:22 am
Forum: Programming
Topic: least square regression matrices
Replies: 4
Views: 1934

Re: least square regression matrices

A third, more tedious option would be to xput <matrix> into matlab/R and xrun an ols.m (from the lesage toolbox or otherwise). However, this requires you have a valid matlab license if opening a matlab connection, and then you still would have to bring the objects you wanted back into eviews.
by CharlieEVIEWS
Thu Sep 03, 2015 3:46 am
Forum: Programming
Topic: For loop and parallel computing
Replies: 5
Views: 1974

Re: For loop and parallel computing

i took a rather crude approach and just opened them each separately from windows explorer :wink: . From my experiences: it might be optimal to open more instances than cores+virtual cores if your desire is to truly max out you CPU (I dont think a single instance will max out a single core, dependent...
by CharlieEVIEWS
Wed Sep 02, 2015 12:27 pm
Forum: Programming
Topic: Approximate string matching....
Replies: 0
Views: 934

Approximate string matching....

Dear all, Are there any known instances of EViews being used for approximate string matching before? I have a very large multifaceted routine which needs to run on machines from which I cannot call other R/MATLAB functions on. I'd be grateful if anyone could provide any experiences or code snippets ...
by CharlieEVIEWS
Wed Sep 02, 2015 12:22 pm
Forum: Programming
Topic: For loop and parallel computing
Replies: 5
Views: 1974

Re: For loop and parallel computing

Ive encountered a similar problem like this before. One solution to max out your cpu useage (spread across cores) is to write the code into chunks/split the variables in your loop into different .prgs, and then open multiple eviews instances: one per core/+virtual cores if hyperthreading. Not ideal,...
by CharlieEVIEWS
Thu Aug 06, 2015 8:44 am
Forum: Data Manipulation
Topic: Dates in a series saved as a day and not fixed character
Replies: 2
Views: 1262

Re: Dates in a series saved as a day and not fixed character

Argh, that must be the only function i didnt try. Thanks Gareth. I think the way dates in series are being written to disk in general is a little bit inconsistent. After extensive testing, EV9 would seldom save it as a date representation, but at other times as a fixed character, although I couldnt ...
by CharlieEVIEWS
Thu Aug 06, 2015 6:17 am
Forum: Data Manipulation
Topic: Dates in a series saved as a day and not fixed character
Replies: 2
Views: 1262

Dates in a series saved as a day and not fixed character

Dear all, I have been collating a large number of individual csvs through unstructed workfiles, transferring dates from one series into another. I have a final 'master' file. However, when I attempt to write the master file to a csv, txt, .dat, xls, xlsx, the dates are being converted into the scala...
by CharlieEVIEWS
Thu Jul 23, 2015 7:40 am
Forum: General Information and Tips and Tricks
Topic: Importing matrices from Matlab
Replies: 15
Views: 7033

Re: Importing matrices from Matlab

whoops! @columnextract. Apologies :D
by CharlieEVIEWS
Thu Jul 23, 2015 7:12 am
Forum: General Information and Tips and Tricks
Topic: Importing matrices from Matlab
Replies: 15
Views: 7033

Re: Importing matrices from Matlab

What error message do you get when you type

Code: Select all

vector myvariable=columnextract(X,4)


replacing X with your matrix, and 4 with the column which relates to your variable? I think the EViews error messages are much clearer than MATLAB to be honest, which are often impossibly cryptic.
by CharlieEVIEWS
Thu Jul 23, 2015 6:19 am
Forum: General Information and Tips and Tricks
Topic: Importing matrices from Matlab
Replies: 15
Views: 7033

Re: Importing matrices from Matlab

The generate tries to create a new series called columnextract(<name>) which is not what you want to be doing. You need to explicitly get the series out of the matrix first, unless it's a vector. Its possible you need to do something like: vector myvariable=columnextract(X,4), which builds a vector ...
by CharlieEVIEWS
Thu Jul 23, 2015 5:01 am
Forum: General Information and Tips and Tricks
Topic: Importing matrices from Matlab
Replies: 15
Views: 7033

Re: Importing matrices from Matlab

Set your cd as usual: xrun cd 'C:\<directory of your function>' then just run the script as you would usually: xrun <yourscriptname> then after your script is finished running (you might want to look into the timeout options if the script is real big) you can use the xget function as described above...
by CharlieEVIEWS
Wed Jul 22, 2015 11:14 am
Forum: General Information and Tips and Tricks
Topic: Tips or tricks for a specific element by element operation
Replies: 2
Views: 2587

Re: Tips or tricks for a specific element by element operati

Had no idea of that function. They should introduce a hand clapping emoji into the forums just for you, Gareth! :idea:

Go to advanced search