I'll try to write my problem in a list to be more understandable:
I have a matlab table T of size 1000x30.
All the data in the last column called 'Class' in the table has certain values of integers ranging from 1 to 20.
So some rows will have the…
I want to create a stacked bar chart from a table. Here there is a MWE of the type of table I am looking at:
clear all;
country1=rand(5,1);
country2=rand(5,1);
country3=rand(5,1);
country4=rand(5,1);
country5=rand(5,1);
date=1990:1994;
…
I have the following code:
L_sum = zeros(height(ABC),1);
for i = 1:height(ABC)
L_sum(i) = sum(ABC{i, ABC.L(i,4:281)});
end
Here my table:
Problem: My sum function sums the entire row values (col. 4-281) per date whereas I only want those…
I have a table as below : (This is a few lines from my table)
T = table({'A';'A';'A';'B';'B';'B';'C';'C';'C';'C'}, {'x';'y';'z';'x';'w';'t';'z';'x';'t';'o'},[5;1;2;2;4;2;2;5;4;1], ...
'VariableNames', {'memberId', 'productId','Rating'});
T:
A…
I am trying to read a test table from an excel sheet , my excel sheet looks something like this
Building location start_date start_time end_date end_time number
Test_Building 1.08 12.06.2016 19:00 12.06.2016 19:30 …
I have a table T as below:
T = table({'A';'A';'B';'B';'B';'B';'C';'C';'D';'D'},...
{'xd';'z';'x';'y';'z';'w';'x';'wh';'z';'w'},...
[4;2;4;1;2;5;2;1;1;5], ...
'VariableNames', {'memberId', 'productId','Rating'});
T =…
I have the following problem in MATLAB.
f1 [4757*256] table
f2 [4757*512] table
f3 [14073*1024] table
While I can easily join f1 and f2 with
f1n = join(f1,f2,'Keys','RowNames');
I cannot do the same with f1 , f3 in
f3n =…
I have a problem I hope you can help me with.
I have imported a large dataset (200000 x 5 cell) in Matlab that has the following structure:
'Year' 'Country' 'X' 'Y' 'Value'
Columns 1 and 5 contain numeric values, while columns 2 to 4 contain…
Overview
I am currently working with a series of .txt files I am importing into MATLAB. For simplicity, I'll show my problem conceptually. Obligatory, I'm new to MATLAB (or programming in general).
These .txt files contain data from tracking a ROI…
\ am dealing with a matrix in MATLAB which is sparse and has many rows and columns. In this case, the row and columns of the matrix are the ids for particular items. Let's assume them as id1 and id2.
It would be nice if the ids for rows and columns…
I have two tables of different row size (which may vary). The variable name is different (no variable name in common). When I try to join these I get an error that no keys are common. Is there a command that would join these two tables? Or how can…
I have a simple table in SqlServer database, simSQLTable. The column headings are:
index, del_date, name
I have a table in MATLAB mytbl, with one row:
num deldate myname
--- ------- ------
1 '07-02-2015 00:00:00.0' 'JenZ'
mycolnames =…
I have a table with Ids and Dates. I would like to retrieve the index of the max date for each Id.
My initial approach is so:
varfun(@max, table, 'Grouping Variables', 'Id', 'InputVariables','Date');
This obviously gives me the date rather than the…
Suppose I have some table (or dataset) object A that includes some factor X (having n distinct values, or "levels") among its variables. Also suppose I have some custom aggregating function agg that takes as input a sequence of rows, and returns a…
If A and B are tables (or datasets) having the same the same columns (and in the same order), then an expression like ismember(A(:, somecols), B(:, somecols)) will produce a boolean array suitable for indexing A with, as in
A(ismember(A(:,…