Community Profile

# Turlough Hughes

##### Last seen: 1일 전
121 2019 이후 총 참여 횟수

#### Turlough Hughes's 배지

세부 정보 보기...

참여 게시물
보기 기준

답변 있음
Matlab corresponding values between matrices?
This will show values of B that exist in A and which are also less than N. result = B(ismember(B,A) & B<N) If you need find ...

2일 전 | 0

답변 있음
Unexpected output form intersect (polyxpoly)
When you're using intersect to do what you have described you need to ensure you have inputs of either two polyshapes, a polyvec...

2일 전 | 1

답변 있음
How to write a loop for this case?
I was also taking the route of putting them into a structure with a fieldname for each month. months = {'Jan','Feb','Mar','Apr'...

3일 전 | 1

답변 있음
Image Processing Edge Detection
You could try the following modification. The main thing I did was use bwareafilt to filter out all but the largest area, then f...

3일 전 | 0

답변 있음
The output matrix values are either 0 or 1 but i want it between [0,1]
When you load in the image the data type is uint8 - unsigned 8 bit integers. So you can't get values between 0 and 1 unless you ...

3일 전 | 0

| 수락됨

답변 있음
dot product between system of vectors
Based on your description you can do the following, transpose the Y and then it's a straight forward case of matrix multiplicati...

3일 전 | 0

답변 있음
Drawing Polygon shapes with data
You can draw the rectangles from your struct as follows: k = size(out,2); figure(), hold on for i = 1:k a = size(out(i)....

4일 전 | 0

| 수락됨

답변 있음
How do i check the frequency of an element in a multi level cell array?
The following loads and concatenates all elements of your cell array, including the 1 x 2 string in result2{1,1}(7), into a sing...

5일 전 | 0

| 수락됨

답변 있음
incorrect input to ezplot function
ezplot requires a function handle as an input whereas you are inputting a vector. Seeing as you have the results as a vector I t...

10일 전 | 1

답변 있음
How can I concatenate two vectors?
How can I 'join vector C and signal to get a matrix? Depends on whether signal is a column vector or row vector If it's a co...

10일 전 | 0

답변 있음
How to do operations on nested cell array?
This should hopefully work but i ament able to test it myself right now as I'm away from my computer. The idea is to pass onecel...

13일 전 | 0

답변 있음
How do i plot maximum values
You weren't actually calling the function. Secondly, the function had no input argument for threshold so I've included that. I a...

20일 전 | 0

| 수락됨

답변 있음
how can i add column in matrix?
Depends what you want in that column but you could for example add a column of zeros as follows: A = [A zeros(size(A,1),1)]

약 1달 전 | 0

| 수락됨

질문

How to run checks on all rows of structure?
I want to check all the rows in the field of a structure and find out which rows are not empty. Can I get an index without using...

약 1달 전 | 답변 수: 1 | 0

### 1

답변

답변 있음
Create loop for multiple excel sheets/documents
One approach would be to use a nested structure with the first level down having a fieldname for each of the files, and then eac...

약 1달 전 | 0

| 수락됨

답변 있음
Import many excel files to Matlab- How to?
If all your data files are in that folder, and only your data files are in that folder and they are formatted the same, the foll...

약 1달 전 | 0

답변 있음
Counting black pixels in a binary image
Let's say you have a binary image B. You can get the number of black pixels by: numBlack=nnz(~B); and the number of white pixe...

약 1달 전 | 1

| 수락됨

답변 있음
Hey Sarah, Let's say you have two tables, as follows: T1=table((1:10).',(10:-1:1).'); T2=table((11:20).',(20:-1:11).',(1:10)....

약 1달 전 | 0

답변 있음
how to conver a string to a array or matrix
You can make a 3d matrix with the third dimensions being the same size as your range. You could then generate the results as fol...

약 1달 전 | 0

답변 있음
Is there a way to vectorize the definition of this matrix ?
Here's one way to do it in one line: z = y.*ones(n,m)==(1:n).'.*ones(n,m); I tested with the following inputs: y=1:10; n=5...

약 1달 전 | 0

| 수락됨

답변 있음
Intersection volume of two 3d alphashapes
Let's say you have two shapes that were developed as follows using column vectors as inputs: shp1=alphaShape(x1,y1,z1); shp2=a...

약 2달 전 | 0

| 수락됨

답변 있음
how to sort an array of elements corresponding to another array in increasing order ?
Have a look at the documentation for sort. You can do it as follows: [b,idx]=sort(b) a=a(idx)

약 2달 전 | 1

| 수락됨

답변 있음
Rename field arrays of a structure that hold identical name
I'm guessing your variable is called CCD_Dyad when you load a given .mat file, so given that you have 54 by 54 matrices I would ...

약 2달 전 | 0

| 수락됨

답변 있음
Check if input is a 4 element vector
if size(x,2)~=4 || ~isvector(x) || ~isnumeric(x) error('Input must be a row vector of length 4') end

약 2달 전 | 0

답변 있음
video processing for motion detection
So the method I suggested was to look at a single pixel, though you could also look at a few, or the entire image histogram, up ...

약 2달 전 | 0

| 수락됨

답변 있음
How to check if a table exists?
If you have a table assigned to the variable T, then I believe you just need to write: if ~exist('T')==1 to check that it does...

약 2달 전 | 0

| 수락됨

답변 있음
Intersecting Two Lines with Varying Angle
So I understand you just want to plot two lines where there is a specific angle between them. If we take one line as line y=0, y...

약 2달 전 | 0

| 수락됨

답변 있음
Filtering data from a table. How can I save values that are higher that 0.5?
You could get an index for each chunk of data as follows: idx=find(a(:,4)>0.5) idx2=find((idx(2:end)-idx(1:end-1))~=1); idx2=...

약 2달 전 | 0

답변 있음
Map a 2D matrix into 3D using loop for allotment along the 3rd dimension
The best way to deal with that is to use a cell array. I've also just renamed 'end' to 'idxend' and 'i' to 'c' as these are pred...

약 2달 전 | 0

| 수락됨

답변 있음
Finding the Sum of a Finite Series
Here I just use some examples for x,y and n, and also instead of 'i' I used 'c' as 'i' is designated for complex numbers. c=1; ...

약 2달 전 | 0