Answered

Bloomberg Connection / Date Format

The code is big and linked with other formulas. One needs Bloomberg connection The prices are in matlab stored. Excel was just...

Bloomberg Connection / Date Format

The code is big and linked with other formulas. One needs Bloomberg connection The prices are in matlab stored. Excel was just...

6 dagen ago | 0

Question

Bloomberg Connection / Date Format

Hi there, According to Bloomberg, when using the history (BDH) function in Excel, one gets different prices depending which tim...

6 dagen ago | 1 answer | 0

Question

Mapping 2 matrices with different number of columns.

Hi, I've got the following 2 matrices and 1 vector UniqFXRates 30x11 double (11 FX rates for 30 data points) InstrFXRates 30x...

ongeveer een maand ago | 1 answer | 0

Question

"Go to" alternative

Hi I have got the following. But it does not do what I what: for f=1:4 for S=[3,4,7,11] Pf1(:,S)=Pf1BM1.allocati...

3 maanden ago | 1 answer | 0

Question

Delete rows in cell arrays

Hi, Have have got the following cell array: How can I delete the first row of the cell and add to each element in the first ...

3 maanden ago | 1 answer | 0

Question

Find the earliest common date and indicator of two date vectors.

Hi, I have got two date vectors: a=[28.02.2019;01.03.2019;04.03.2019;...] and b=[01.03.2019;04.03.2019;...] How to find the ea...

3 maanden ago | 2 answers | 0

Question

Multiplication of 2 3d matrices

Hi, I have got 2 3d matrices: NormClassRetPf(dates,factors,classes) and TotWeightsPf(dates,factors,classes). nDates=51 nFacto...

3 maanden ago | 2 answers | 0

Question

Assignment with 0 - Alternative

Hi everybody, I have got the following code: PortMembers=369x1 cell with ISINS GlData.instrISIN(:,1) = 1640x1 cell with ISIS ...

4 maanden ago | 0 answers | 0

Question

Logicals with empty double column vectors

Hi I have got this code: a=Pf_ID; %--> 5x1cell b=magic(5); c=find(cellfun(@isempty,a)); ...

4 maanden ago | 1 answer | 0

Question

Dynamic struct names with strings.

Hi I have got a 4x1 cell (named= RankFileNames) with the following chars '0_1_workspace_20190410.mat' '0_2_workspace_20190228...

4 maanden ago | 1 answer | 0

Answered

Code that makes matlab jumping loops without fininishing the remaining iterations.

Thank you for your answer. I wasn't clear. Here is the procedure I woul like: 1) First iteration r 2) First iteration d, exce...

Code that makes matlab jumping loops without fininishing the remaining iterations.

Thank you for your answer. I wasn't clear. Here is the procedure I woul like: 1) First iteration r 2) First iteration d, exce...

5 maanden ago | 0

Question

Code that makes matlab jumping loops without fininishing the remaining iterations.

Hi, I have got the following 2 loops: for d=1:nDates %loop over rebdates for r=1:nRebDates ind=ismember(PortMem...

5 maanden ago | 2 answers | 0

Question

Nested Loops and break command

Hi, below you can see my code and my question is written in green after the command break. Can you help me?

5 maanden ago | 0 answers | 0

Question

Jump to next loop (alternative goto)

Hi, my code is mentioned below. The question is green after % if statement. May you help me? function NewRanks=createRebRankin...

5 maanden ago | 1 answer | 0

Question

Alternative for an increasing number of conditions in if-statements

Dear all, My issue: I have got a date vector with portfolio rebalancing dates. As the time goes by, the vector length increas...

5 maanden ago | 0 answers | 0

Question

Portfolio returns with rebalancing dates and changing portfolio members

Hi, Is there any specific portfolio matlab code, which can calculate Portfolio returns/Performance for a given period by taken ...

5 maanden ago | 0 answers | 0

Question

Download Data from Excel worksheet: Automatically changing range in Excel

Hi I will have to download data from excel worksheets on a daily bases. I used the following formula: T=readtable('xxx_Ang_Sek...

5 maanden ago | 1 answer | 0

Question

Tables: Transform Variablenames

Hi I downloaded data from an excel worksheet to matlab. Matlab creates a table. Matlab inserts the first row of the data in exc...

5 maanden ago | 2 answers | 0

Answered

Error on opening a .mat file.

The file is 644'234 KB big. My computer is not the latest one. How to check if my .mat file is in ASCII format?

Error on opening a .mat file.

The file is 644'234 KB big. My computer is not the latest one. How to check if my .mat file is in ASCII format?

8 maanden ago | 0

Question

Error on opening a .mat file.

I have got a rather big .mat file. When I try to open it an error message pops up: "File might be corrupt." Here is a more det...

8 maanden ago | 2 answers | 0

Answered

How to use Matlab's unit test framework component verifyError to verify an error from a MEX function

Hi Andy, perhaps you can help me. how to only test the error message? I would like to test the following message written i...

How to use Matlab's unit test framework component verifyError to verify an error from a MEX function

Hi Andy, perhaps you can help me. how to only test the error message? I would like to test the following message written i...

10 maanden ago | 0

Question

How to unit test with verifyWarning?

Hello, I am trying to apply the function verifyWarning on the following function: function [adjdate] = AdjStartDate(startDate...

10 maanden ago | 2 answers | 0

Question

How to unit test with verifyError?

Hi everyone, I am trying to unit test the following function: function res=add5(x) % ADD5 Increment input by 5. if ~i...

10 maanden ago | 1 answer | 1

Question

Unit tests with verifyError

Hello, I am trying to unit test the error message in the function below, which pops up if I input an incorrect fieldname: 'ALT...

10 maanden ago | 0 answers | 0

Question

How to unit test with verifyWarning?

Hello, I am unit testing the following function: function [adjdate] = AdjStartDate(startDate) if ~strcmp(startDate,datestr...

10 maanden ago | 0 answers | 0

Question

How to unit test a long function?

I have got a long function, which downloads financial data from bloombberg, aggregates, cleans it etc. Now I will have to unit ...

10 maanden ago | 1 answer | 0

Question

Creating Unit tests on Functions using classes.

Hi there, I've got rather a long function which I will have to test (unit test). The function contains many iterim results whic...

10 maanden ago | 0 answers | 0

Question

Deleting required object properties data for calculating dependent properties data without deleting the data in dependent properties.

Hi everybody. I created a class using the knowledge in https://ch.mathworks.com/help/matlab/matlab_oop/example-representing-stru...

11 maanden ago | 0 answers | 0

Question

Getting access of an output variable from a function or script which is saved in a different folder.

Hi everybody, In one folder (P:\MATLAB\SystematischesPM\Data) I have got a script named "DataDownload". It returns a cell 20x1 ...

12 maanden ago | 1 answer | 0

Answered

Object Oriented Programming - Leaving properties from objects empty.

Thanks a lot Adam and Matt. I am quite new in OOP. Therefore I would like the following question. In my project the objects (=st...

Object Oriented Programming - Leaving properties from objects empty.

Thanks a lot Adam and Matt. I am quite new in OOP. Therefore I would like the following question. In my project the objects (=st...

12 maanden ago | 0