Month: April 2025
Reading multiple sheets from an excel file
I have an excel spreadsheet and the data is seperated into a different sheet for each year but I want to have all of the years worth of data in one table so I was wondering what the best way to approach this is? Right now my code only gets the data from 2007 and thats it.
opt=detectImportOptions(‘BC1 2007-2020.xlsx’);
opt.VariableTypes(3)={‘double’};
BC1=readtable(‘BC1 2007-2020.xlsx’,opt);
BC1.Date=datetime(BC1{:,1},’InputFormat’,’dd/MM/yy HH:mm:ss’);
BC1=table2timetable(BC1);
plot(BC1.Date,BC1.WaterLevel_Meters);I have an excel spreadsheet and the data is seperated into a different sheet for each year but I want to have all of the years worth of data in one table so I was wondering what the best way to approach this is? Right now my code only gets the data from 2007 and thats it.
opt=detectImportOptions(‘BC1 2007-2020.xlsx’);
opt.VariableTypes(3)={‘double’};
BC1=readtable(‘BC1 2007-2020.xlsx’,opt);
BC1.Date=datetime(BC1{:,1},’InputFormat’,’dd/MM/yy HH:mm:ss’);
BC1=table2timetable(BC1);
plot(BC1.Date,BC1.WaterLevel_Meters); I have an excel spreadsheet and the data is seperated into a different sheet for each year but I want to have all of the years worth of data in one table so I was wondering what the best way to approach this is? Right now my code only gets the data from 2007 and thats it.
opt=detectImportOptions(‘BC1 2007-2020.xlsx’);
opt.VariableTypes(3)={‘double’};
BC1=readtable(‘BC1 2007-2020.xlsx’,opt);
BC1.Date=datetime(BC1{:,1},’InputFormat’,’dd/MM/yy HH:mm:ss’);
BC1=table2timetable(BC1);
plot(BC1.Date,BC1.WaterLevel_Meters); excel MATLAB Answers — New Questions
Tomcat in the Crosshairs: New Research Reveals Ongoing Attacks
News headlines reported that it took just 30 hours for attackers to exploit a newly discovered vulnerability in Apache Tomcat servers. But what does this mean for workloads relying on Tomcat? Aqua Nautilus researchers discovered a new attack campaign targeting Apache Tomcat. In this blog, we shed light on newly discovered malware that targets Tomcat servers to hijack resources.
News headlines reported that it took just 30 hours for attackers to exploit a newly discovered vulnerability in Apache Tomcat servers. But what does this mean for workloads relying on Tomcat? Aqua Nautilus researchers discovered a new attack campaign targeting Apache Tomcat. In this blog, we shed light on newly discovered malware that targets Tomcat servers to hijack resources.
Read More
Pass bus signals to a function as an array (Stateflow)
Hello!
I’m working within stateflow and defining a transition check:
[checkInRange(User_CMDs.r,0,1)==1]
Check In range is a simple function as follows and returns true if all inputs are true (In Range):
function result = checkInRange(input,request,tolerance)
result = abs(request – input) <= tolerance;
result = all(result(:));
end
Ive been able to pass arrays as input to the function, however i am trying to define a transition and for a state within simulink. The User_CMD.r is a bus with 4 singals called X1, X2, X3 and X4. I need all of these to be in range for state transition. Is there a way of doing this without doing it as below?
[checkInRange([User_CMDs.r.X1,User_CMDs.r.X1,User_CMDs.r.X1,User_CMDs.r.X1], 0,1)==1]Hello!
I’m working within stateflow and defining a transition check:
[checkInRange(User_CMDs.r,0,1)==1]
Check In range is a simple function as follows and returns true if all inputs are true (In Range):
function result = checkInRange(input,request,tolerance)
result = abs(request – input) <= tolerance;
result = all(result(:));
end
Ive been able to pass arrays as input to the function, however i am trying to define a transition and for a state within simulink. The User_CMD.r is a bus with 4 singals called X1, X2, X3 and X4. I need all of these to be in range for state transition. Is there a way of doing this without doing it as below?
[checkInRange([User_CMDs.r.X1,User_CMDs.r.X1,User_CMDs.r.X1,User_CMDs.r.X1], 0,1)==1] Hello!
I’m working within stateflow and defining a transition check:
[checkInRange(User_CMDs.r,0,1)==1]
Check In range is a simple function as follows and returns true if all inputs are true (In Range):
function result = checkInRange(input,request,tolerance)
result = abs(request – input) <= tolerance;
result = all(result(:));
end
Ive been able to pass arrays as input to the function, however i am trying to define a transition and for a state within simulink. The User_CMD.r is a bus with 4 singals called X1, X2, X3 and X4. I need all of these to be in range for state transition. Is there a way of doing this without doing it as below?
[checkInRange([User_CMDs.r.X1,User_CMDs.r.X1,User_CMDs.r.X1,User_CMDs.r.X1], 0,1)==1] stateflow, signal bus, bus MATLAB Answers — New Questions
Interactive point selection 3D points
Hello,
I need your help.
In the image bellow (hopefully it did work this time) there is a three-dimensional tooth on the left (with its three-dimensional coordinates, of course) and on the left the same tooth but in a two-dimensional parameterised disc. The order of the points on the 2D and 3D vectors are the same, that is, the points are corresponding.
I woud like to select a point on the 3D tooth and get the same point marked on the right 2D tooth. I can do this the other way around, that is, selecting a point on the disc and then getting the correspondent on the 3D figure.
My method for doing this on the 2D was with the function getpts, which gives me the coordinates of the mouse where I click. I then take the nearest neighbour of that point (or points) and plot the corresponding points on the 3D figure with its correct indexes.
So my question is, is there a similar function to getpts() for a 3D figure?
Thank you :)Hello,
I need your help.
In the image bellow (hopefully it did work this time) there is a three-dimensional tooth on the left (with its three-dimensional coordinates, of course) and on the left the same tooth but in a two-dimensional parameterised disc. The order of the points on the 2D and 3D vectors are the same, that is, the points are corresponding.
I woud like to select a point on the 3D tooth and get the same point marked on the right 2D tooth. I can do this the other way around, that is, selecting a point on the disc and then getting the correspondent on the 3D figure.
My method for doing this on the 2D was with the function getpts, which gives me the coordinates of the mouse where I click. I then take the nearest neighbour of that point (or points) and plot the corresponding points on the 3D figure with its correct indexes.
So my question is, is there a similar function to getpts() for a 3D figure?
Thank you Hello,
I need your help.
In the image bellow (hopefully it did work this time) there is a three-dimensional tooth on the left (with its three-dimensional coordinates, of course) and on the left the same tooth but in a two-dimensional parameterised disc. The order of the points on the 2D and 3D vectors are the same, that is, the points are corresponding.
I woud like to select a point on the 3D tooth and get the same point marked on the right 2D tooth. I can do this the other way around, that is, selecting a point on the disc and then getting the correspondent on the 3D figure.
My method for doing this on the 2D was with the function getpts, which gives me the coordinates of the mouse where I click. I then take the nearest neighbour of that point (or points) and plot the corresponding points on the 3D figure with its correct indexes.
So my question is, is there a similar function to getpts() for a 3D figure?
Thank you 3d getpts MATLAB Answers — New Questions
how to make transformation in mp4 vedio
i have two vedio of mp4.i want to apply some tranformation on it and run the tranform vedio.i have wriiten the code but contently facing the error.i even tried "NumberOfFrames" but it is unrecongnized in my matlab
code is here
% read videos
vid1 = VideoReader(‘video1.mp4’);
vid2 = VideoReader(‘vedio2.mp4’);
% read first frame from each video
frame1 = readFrame(vid1);
frame2 = readFrame(vid2);
% create a figure
fig = figure;
while hasFrame(vid1) && hasFrame(vid2)
% read frames from each video
frame1 = readFrame(vid1);
frame2 = readFrame(vid2);
% perform geometric transformations
frame1_scaled = imresize(frame1, 0.5);
frame1_sheared = imresize(frame1, [size(frame1,1) size(frame1,2)*0.8]);
frame1_rotated = imrotate(frame1, 30, ‘crop’);
frame2_scaled = imresize(frame2, 0.5);
frame2_sheared = imresize(frame2, [size(frame2,1) size(frame2,2)*0.8]);
frame2_rotated = imrotate(frame2, -30, ‘crop’);
% concatenate frames
combined_frame = cat(2, cat(1, frame1, frame1_scaled, frame1_sheared, frame1_rotated), …
cat(1, frame2, frame2_scaled, frame2_sheared, frame2_rotated));
% display frames
imshow(combined_frame, ‘Parent’, fig);
drawnow;
end
error that i facing is
Error using cat
Dimensions
of
arrays
being
concatenated
are
not
consistent.
Error in untitled (line 27)
combined_frame = cat(2, cat(1, frame1, frame1_scaled, frame1_sheared, frame1_rotated), …i have two vedio of mp4.i want to apply some tranformation on it and run the tranform vedio.i have wriiten the code but contently facing the error.i even tried "NumberOfFrames" but it is unrecongnized in my matlab
code is here
% read videos
vid1 = VideoReader(‘video1.mp4’);
vid2 = VideoReader(‘vedio2.mp4’);
% read first frame from each video
frame1 = readFrame(vid1);
frame2 = readFrame(vid2);
% create a figure
fig = figure;
while hasFrame(vid1) && hasFrame(vid2)
% read frames from each video
frame1 = readFrame(vid1);
frame2 = readFrame(vid2);
% perform geometric transformations
frame1_scaled = imresize(frame1, 0.5);
frame1_sheared = imresize(frame1, [size(frame1,1) size(frame1,2)*0.8]);
frame1_rotated = imrotate(frame1, 30, ‘crop’);
frame2_scaled = imresize(frame2, 0.5);
frame2_sheared = imresize(frame2, [size(frame2,1) size(frame2,2)*0.8]);
frame2_rotated = imrotate(frame2, -30, ‘crop’);
% concatenate frames
combined_frame = cat(2, cat(1, frame1, frame1_scaled, frame1_sheared, frame1_rotated), …
cat(1, frame2, frame2_scaled, frame2_sheared, frame2_rotated));
% display frames
imshow(combined_frame, ‘Parent’, fig);
drawnow;
end
error that i facing is
Error using cat
Dimensions
of
arrays
being
concatenated
are
not
consistent.
Error in untitled (line 27)
combined_frame = cat(2, cat(1, frame1, frame1_scaled, frame1_sheared, frame1_rotated), … i have two vedio of mp4.i want to apply some tranformation on it and run the tranform vedio.i have wriiten the code but contently facing the error.i even tried "NumberOfFrames" but it is unrecongnized in my matlab
code is here
% read videos
vid1 = VideoReader(‘video1.mp4’);
vid2 = VideoReader(‘vedio2.mp4’);
% read first frame from each video
frame1 = readFrame(vid1);
frame2 = readFrame(vid2);
% create a figure
fig = figure;
while hasFrame(vid1) && hasFrame(vid2)
% read frames from each video
frame1 = readFrame(vid1);
frame2 = readFrame(vid2);
% perform geometric transformations
frame1_scaled = imresize(frame1, 0.5);
frame1_sheared = imresize(frame1, [size(frame1,1) size(frame1,2)*0.8]);
frame1_rotated = imrotate(frame1, 30, ‘crop’);
frame2_scaled = imresize(frame2, 0.5);
frame2_sheared = imresize(frame2, [size(frame2,1) size(frame2,2)*0.8]);
frame2_rotated = imrotate(frame2, -30, ‘crop’);
% concatenate frames
combined_frame = cat(2, cat(1, frame1, frame1_scaled, frame1_sheared, frame1_rotated), …
cat(1, frame2, frame2_scaled, frame2_sheared, frame2_rotated));
% display frames
imshow(combined_frame, ‘Parent’, fig);
drawnow;
end
error that i facing is
Error using cat
Dimensions
of
arrays
being
concatenated
are
not
consistent.
Error in untitled (line 27)
combined_frame = cat(2, cat(1, frame1, frame1_scaled, frame1_sheared, frame1_rotated), … video processing, transformation MATLAB Answers — New Questions
Correct way to calculate the dominant frequency of time series signal?
My dataset consists of two parameters: time (in micro second) and amplitude (Attached):
I am particularly interested in analyzing the fluctuation of the dominant frequency across the entire dataset. Additionally, I want to examine how the frequency content changes as a function of time. For instance, in time intervals such as 0–200 ms, 100–300 ms, 300–500 ms, and so on.
I attempted multiple approaches, but the results are not very consistent. I would be interested in getting a second opinion.
Thanks in Advance!My dataset consists of two parameters: time (in micro second) and amplitude (Attached):
I am particularly interested in analyzing the fluctuation of the dominant frequency across the entire dataset. Additionally, I want to examine how the frequency content changes as a function of time. For instance, in time intervals such as 0–200 ms, 100–300 ms, 300–500 ms, and so on.
I attempted multiple approaches, but the results are not very consistent. I would be interested in getting a second opinion.
Thanks in Advance! My dataset consists of two parameters: time (in micro second) and amplitude (Attached):
I am particularly interested in analyzing the fluctuation of the dominant frequency across the entire dataset. Additionally, I want to examine how the frequency content changes as a function of time. For instance, in time intervals such as 0–200 ms, 100–300 ms, 300–500 ms, and so on.
I attempted multiple approaches, but the results are not very consistent. I would be interested in getting a second opinion.
Thanks in Advance! time series, fft MATLAB Answers — New Questions
prev value in a stateflow chart
Stateflow documentation:
…To detect changes, the chart automatically double-buffers these values in local variables, as follows:
var_name_prev Value of data at the beginning of the last time step
var_name_start Value of data at the beginning of the current time step
Question: do I have read access to the buffered variables? I want to use them for calculations inside the stateflow chart.Stateflow documentation:
…To detect changes, the chart automatically double-buffers these values in local variables, as follows:
var_name_prev Value of data at the beginning of the last time step
var_name_start Value of data at the beginning of the current time step
Question: do I have read access to the buffered variables? I want to use them for calculations inside the stateflow chart. Stateflow documentation:
…To detect changes, the chart automatically double-buffers these values in local variables, as follows:
var_name_prev Value of data at the beginning of the last time step
var_name_start Value of data at the beginning of the current time step
Question: do I have read access to the buffered variables? I want to use them for calculations inside the stateflow chart. stateflow, double-buffer MATLAB Answers — New Questions
How SharePoint Online Restricted Content Discovery Works
Restricted Content Discovery Hides SharePoint Content from Copilot and Agents
The problem of poor permission management has surfaced from time to time in the history of SharePoint. The Office Delve app caused the last big upheaval within Microsoft 365 when it demonstrated an uncanny ability to surface sensitive documents to user view. Of course, Delve was never the problem. The issue is due to careless permission assignment, usually at site level.
When Microsoft launched Copilot in March 2023, it soon became apparent that Copilot is even better than Delve at finding and reusing documents, including files that an organization would prefer to remain restricted. Microsoft’s short-term answer was Restricted SharePoint Search, a horrible but expedient solution that works on the basis of an allow list for enterprise search which restricts users to only being able to search approved sites. Copilot always works as the signed in user, so the limits applied to users apply to Copilot to stop the AI using material stored in unapproved sites in its responses.
Restricted Content Discovery (RCD) is the latest solution to control unfettered access to confidential information stored in SharePoint Online sites. RCD is part of the SharePoint Advanced Management (SAM) suite. Microsoft is allowing tenants with Microsoft 365 Copilot licenses to use SAM via a code update that’s slowly deploying.
How Restricted Content Discovery Works
Restricted Content Delivery works by adding a flag to files stored in designated SharePoint Online sites. When an administrator marks a site for RCD through the SharePoint admin center or PowerShell. Figure 1 shows the “restrict content from Microsoft 365 Copilot” option in the admin center. When a site is selected for RCD, SharePoint sets a site-level property that causes index updates for every file in the site. Although RCD is applied at a site basis, SharePoint indexing happens at the file level, so a fan-out process must find and reindex every file in a site before RCD becomes effective for that site.
The time required to update the index for a site is highly dependent on the number of items in the site. Microsoft says that “for sites with more than 500,000 items, the Restricted Content Discovery update could take more than a week to fully process and reflect in search and Copilot.”

The indexing update does not remove items from the tenant index. If it did, items would be unavailable for eDiscovery searches, auto-label policies for retention and sensitivity labels, and other solutions. Instead, the flag set on files instructs Copilot to ignore those files when it consults the Graph to find matching content to help ground user prompts. The same approach is used by the Data Loss Prevention (DLP) policy to block Copilot access to files assigned specific sensitivity labels.
The block applies to anywhere Copilot for Microsoft 365 can use SharePoint Online files, including Copilot agents.
RCD Management with PowerShell
PowerShell can be used to manage RCD for sites. Make sure that you use a recent version of the SharePoint Online management module (I used Microsoft.Online.SharePoint.PowerShell version 16.0.25715.12000). For example, to enable RCD for a site, run the Set-SPOSite cmdlet to set the RestrictContentOrgWideSearch property to $true.
Set-SPOSite -Identity https://office365itpros.sharepoint.com/sites/rabilling -RestrictContentOrgWideSearch $true
To remove RCD from a site, set the value for RestrictContentOrgWideSearch to $false:
Set-SPOSite -Identity https://office365itpros.sharepoint.com/sites/rabilling -RestrictContentOrgWideSearch $false
Much the same reindexing process must occur before files in sites where RCD is disabled after being enabled before files become available to Copilot.
To generate a list of sites with RCD enabled, run the Start-SPORestrictedContentDiscoverabilityReport command to create a job on a queue for processing. The Get-SPORestrictedContentDiscoverabilityReport cmdlet reports the status for the job, which eventually reports “Completed.”
Start-SPORestrictedContentDiscoverabilityReport Generating the report will take some time. Are you sure you want to proceed? Continue with this operation? [Y] Yes [N] No [?] Help (default is "Y"): y RunspaceId : 1d839c7e-c0bf-4c11-be94-20179f2335e2 Id : 02aa91ea-5e12-43de-91a1-a58275d3b201 CreatedDateTimeInUtc : 03/31/2025 16:09:52 Status : NotStarted Get-SPORestrictedContentDiscoverabilityReport RunspaceId : 1d839c7e-c0bf-4c11-be94-20179f2335e2 Id : 02aa91ea-5e12-43de-91a1-a58275d3b201 CreatedDateTimeInUtc : 03/31/2025 17:03:52 Status : Completed
To download the RCD insights report, run the Get-SPORestrictedContentDiscoverabilityReport cmdlet and pass the GUID (id) for the report. This value is shown in the Get-SPORestrictedContentDiscoverabilityReport output:
Get-SPORestrictedContentDiscoverabilityReport –Action Download –ReportId 02aa91ea-5e12-43de-91a1-a58275d3b201 Report RestrictedContentDiscoverabilityReport_1743437651407.csv downloaded successfully
Microsoft documentation says that “the downloaded report is located on the path where the command was run.” This is incorrect. The file ends up in whatever folder the PowerShell session starts up in. In my case, I ran the job when positioned in c:temp and the file ended up in c:windowssystem32. The easy fix here is to use a PowerShell profile to define the folder where PowerShell starts up.
The contents of the “insights” report aren’t too exciting (Figure 2) and could be easily generated by looping through sites with PowerShell to find those with the flag set.

Restricted Content Discovery for All
It’s a reasonable guess that any Microsoft 365 tenant that’s interested in Copilot has some sensitive information stored in SharePoint Online sites. If you’re in this situation, you should consider RCD as the front-line method to prevent that information leaking out through Copilot. I’d also deploy the DLP policy to restrict Copilot access as a backup. Between the two lines of defence, it’s unlikely that inadvertent disclosure of confidential data will happen, and that’s a good thing.
Insight like this doesn’t come easily. You’ve got to know the technology and understand how to look behind the scenes. Benefit from the knowledge and experience of the Office 365 for IT Pros team by subscribing to the best eBook covering Office 365 and the wider Microsoft 365 ecosystem.
How to arrange elements in one array to match the position of elements in a second array?
If I have two arrays A and B as displayed below, how can I rearrange B such that a new boolean array Ba which corresponds to the values of array B can be resorted according to the values of array A instead?
For example, if I have:
A =
1 5 3 2 4 4 2 2 3 5
2 1 1 2 0 1 1 1 0 0
30 22 23 25 -1 30 18 25 -1 -1
B =
1 2 2 2 3 3 4 4 5 5
2 1 1 2 0 1 0 1 0 1
30 18 25 25 -1 23 -1 30 -1 22
Ba =
0 0 1 0 1 0 0 0 0 0
Note that array B is simply the sorted version of array A according to the first row in an ascended order. It is resorted twice according to the second row in an ascended order for the values in row 1 that equal one another (e.g., if there are multiples elements equal to 3 in row 1, then the array will sort by the second row instead, so if the second row has values 3 3 3 3 3; 2 6 3 9 1, it will then be sorted to 3 3 3 3 3; 1 2 3 6 9)
I only mentioned this in case reverse sorting might work easier than entirely rearranging the position of the array.
I want to rearrange array B and Ba such that it corresponds to the positioning of array A.
So the new arrays would look like this:
A =
1 5 3 2 4 4 2 2 3 5
2 1 1 2 0 1 1 1 0 0
30 22 23 25 -1 30 18 25 -1 -1
Aa =
0 0 0 0 0 0 0 1 1 0
The new array would essentially match A, and the array Aa is the same array Ba but now rearranged so that it follows the arrangement of A rather than B.
I am not entirely sure how to write the MATLAB code to accomplish this. All help is appreciated!If I have two arrays A and B as displayed below, how can I rearrange B such that a new boolean array Ba which corresponds to the values of array B can be resorted according to the values of array A instead?
For example, if I have:
A =
1 5 3 2 4 4 2 2 3 5
2 1 1 2 0 1 1 1 0 0
30 22 23 25 -1 30 18 25 -1 -1
B =
1 2 2 2 3 3 4 4 5 5
2 1 1 2 0 1 0 1 0 1
30 18 25 25 -1 23 -1 30 -1 22
Ba =
0 0 1 0 1 0 0 0 0 0
Note that array B is simply the sorted version of array A according to the first row in an ascended order. It is resorted twice according to the second row in an ascended order for the values in row 1 that equal one another (e.g., if there are multiples elements equal to 3 in row 1, then the array will sort by the second row instead, so if the second row has values 3 3 3 3 3; 2 6 3 9 1, it will then be sorted to 3 3 3 3 3; 1 2 3 6 9)
I only mentioned this in case reverse sorting might work easier than entirely rearranging the position of the array.
I want to rearrange array B and Ba such that it corresponds to the positioning of array A.
So the new arrays would look like this:
A =
1 5 3 2 4 4 2 2 3 5
2 1 1 2 0 1 1 1 0 0
30 22 23 25 -1 30 18 25 -1 -1
Aa =
0 0 0 0 0 0 0 1 1 0
The new array would essentially match A, and the array Aa is the same array Ba but now rearranged so that it follows the arrangement of A rather than B.
I am not entirely sure how to write the MATLAB code to accomplish this. All help is appreciated! If I have two arrays A and B as displayed below, how can I rearrange B such that a new boolean array Ba which corresponds to the values of array B can be resorted according to the values of array A instead?
For example, if I have:
A =
1 5 3 2 4 4 2 2 3 5
2 1 1 2 0 1 1 1 0 0
30 22 23 25 -1 30 18 25 -1 -1
B =
1 2 2 2 3 3 4 4 5 5
2 1 1 2 0 1 0 1 0 1
30 18 25 25 -1 23 -1 30 -1 22
Ba =
0 0 1 0 1 0 0 0 0 0
Note that array B is simply the sorted version of array A according to the first row in an ascended order. It is resorted twice according to the second row in an ascended order for the values in row 1 that equal one another (e.g., if there are multiples elements equal to 3 in row 1, then the array will sort by the second row instead, so if the second row has values 3 3 3 3 3; 2 6 3 9 1, it will then be sorted to 3 3 3 3 3; 1 2 3 6 9)
I only mentioned this in case reverse sorting might work easier than entirely rearranging the position of the array.
I want to rearrange array B and Ba such that it corresponds to the positioning of array A.
So the new arrays would look like this:
A =
1 5 3 2 4 4 2 2 3 5
2 1 1 2 0 1 1 1 0 0
30 22 23 25 -1 30 18 25 -1 -1
Aa =
0 0 0 0 0 0 0 1 1 0
The new array would essentially match A, and the array Aa is the same array Ba but now rearranged so that it follows the arrangement of A rather than B.
I am not entirely sure how to write the MATLAB code to accomplish this. All help is appreciated! array, sort MATLAB Answers — New Questions
STL to solid 3d matrix
Is there a way to import STL and save it as 3D matrix and stlil maintain its size? Patch is a good function to import stl, I need voxelisation of the mesh so I can slice the 2D data out of it.
This is a good work by Adam , but it does not maintain the size and ratio:
https://uk.mathworks.com/matlabcentral/fileexchange/27390-mesh-voxelisation
RegardsIs there a way to import STL and save it as 3D matrix and stlil maintain its size? Patch is a good function to import stl, I need voxelisation of the mesh so I can slice the 2D data out of it.
This is a good work by Adam , but it does not maintain the size and ratio:
https://uk.mathworks.com/matlabcentral/fileexchange/27390-mesh-voxelisation
Regards Is there a way to import STL and save it as 3D matrix and stlil maintain its size? Patch is a good function to import stl, I need voxelisation of the mesh so I can slice the 2D data out of it.
This is a good work by Adam , but it does not maintain the size and ratio:
https://uk.mathworks.com/matlabcentral/fileexchange/27390-mesh-voxelisation
Regards stl, patch, voxelisation MATLAB Answers — New Questions
How to get the values of x axis only visible at the bottom subplots?
Hi,
I have a series of subplots (5×4). Every subplot has the same x axis and the same limits. At the moment, I have the values of x axis visible in every subplot. I would like to have the values only visible at the bottom subplots, so that the figure would be simpler. I already edited the code so that the x label is only visible at the bottom subplots. But how do I do the same to the x axis values?
I tried turning of the ‘XTick’
set(gca,’XTick’,[]);
This worked, however, now the grid also turned off. How can I get the values to be only at the bottom subplots, and the grid on?
The same goes for y axis. I only want the values of the y axis to be visible at the left subplots.
Thank you in advance for any answers!Hi,
I have a series of subplots (5×4). Every subplot has the same x axis and the same limits. At the moment, I have the values of x axis visible in every subplot. I would like to have the values only visible at the bottom subplots, so that the figure would be simpler. I already edited the code so that the x label is only visible at the bottom subplots. But how do I do the same to the x axis values?
I tried turning of the ‘XTick’
set(gca,’XTick’,[]);
This worked, however, now the grid also turned off. How can I get the values to be only at the bottom subplots, and the grid on?
The same goes for y axis. I only want the values of the y axis to be visible at the left subplots.
Thank you in advance for any answers! Hi,
I have a series of subplots (5×4). Every subplot has the same x axis and the same limits. At the moment, I have the values of x axis visible in every subplot. I would like to have the values only visible at the bottom subplots, so that the figure would be simpler. I already edited the code so that the x label is only visible at the bottom subplots. But how do I do the same to the x axis values?
I tried turning of the ‘XTick’
set(gca,’XTick’,[]);
This worked, however, now the grid also turned off. How can I get the values to be only at the bottom subplots, and the grid on?
The same goes for y axis. I only want the values of the y axis to be visible at the left subplots.
Thank you in advance for any answers! subplot, axes, xlabel, xvalue MATLAB Answers — New Questions
Are dlnetworks supposed to be allowed to have output layers?
Are dlnetworks allowed to have output layers? In the following code, I manage to create one, so the answer would seem to be yes.
layers= [imageInputLayer([1,1,1]) , reluLayer(Name=’relu’) ] ;
dln = replaceLayer( dlnetwork(layers) ,’relu’, regressionLayer);
class(dln)
dln.Layers
However, when I try to create this more directly, an error is raised:
dln = dlnetwork( [imageInputLayer([1,1,1]) , regressionLayer] )
Have I found an unintended backdoor?Are dlnetworks allowed to have output layers? In the following code, I manage to create one, so the answer would seem to be yes.
layers= [imageInputLayer([1,1,1]) , reluLayer(Name=’relu’) ] ;
dln = replaceLayer( dlnetwork(layers) ,’relu’, regressionLayer);
class(dln)
dln.Layers
However, when I try to create this more directly, an error is raised:
dln = dlnetwork( [imageInputLayer([1,1,1]) , regressionLayer] )
Have I found an unintended backdoor? Are dlnetworks allowed to have output layers? In the following code, I manage to create one, so the answer would seem to be yes.
layers= [imageInputLayer([1,1,1]) , reluLayer(Name=’relu’) ] ;
dln = replaceLayer( dlnetwork(layers) ,’relu’, regressionLayer);
class(dln)
dln.Layers
However, when I try to create this more directly, an error is raised:
dln = dlnetwork( [imageInputLayer([1,1,1]) , regressionLayer] )
Have I found an unintended backdoor? dlnetwork, output layer MATLAB Answers — New Questions
Inserting Table from Matlab into Powerpoint slide
Does anyone know how to insert a table from MATLAB to a powerpoint slide?
For example:
header = cell{1,3};
header = {‘Header1’ ‘Header2’ ‘Header 3’};
data= [1, 2, 3;
1, 4, 9;];
How would one output this to powerpoint? I’ve seen the Matlab figures to powerpoint copying and pasting, but not sure how to insert a table.
Thanks for your help!Does anyone know how to insert a table from MATLAB to a powerpoint slide?
For example:
header = cell{1,3};
header = {‘Header1’ ‘Header2’ ‘Header 3’};
data= [1, 2, 3;
1, 4, 9;];
How would one output this to powerpoint? I’ve seen the Matlab figures to powerpoint copying and pasting, but not sure how to insert a table.
Thanks for your help! Does anyone know how to insert a table from MATLAB to a powerpoint slide?
For example:
header = cell{1,3};
header = {‘Header1’ ‘Header2’ ‘Header 3’};
data= [1, 2, 3;
1, 4, 9;];
How would one output this to powerpoint? I’ve seen the Matlab figures to powerpoint copying and pasting, but not sure how to insert a table.
Thanks for your help! powerpoint, table, inserting MATLAB Answers — New Questions
Office 365 for IT Pros April 2025 Update
Monthly Update #118 for the Office 365 for IT Pros eBook
The Office 365 for IT Pros writing team is delighted to announce the availability of the April 2025 update (monthly update #118) for the Office 365 for IT Pros eBook. Readers can check the update number of the book on the inside front cover. Details of the update are available in our change log.
The Automating Microsoft 365 with PowerShell eBook is updated for April 2025 too. Its current version is 10.1. The new PDF and EPUB files are available to Office 365 for IT Pros subscribers and those who bought a separate subscription for the PowerShell book.
Subscribers can download the updated files from their Gumroad account or by using the download link in the receipt they received by email following their original purchase. The link in the receipt always accesses the latest files. See our FAQ for more information about how to download updates.
Sending Messages to the Wrong Place
There’s been quite a furore about messages being delivered to the wrong person recently. Leaving the politics aside, the situation is a reminder that the same thing could happen in a Microsoft 365 tenant if a user created an Outlook contact group and included someone who shouldn’t receive sensitive or confidential information in the group members. It’s easy to do because Outlook (Figure 1) doesn’t limit membership to a particular type of recipient. The membership of a personal contact group can include existing contacts, people from the address list (GAL), or new contacts.

Administrators have no idea if people use Outlook contact groups because these objects are stored in user mailboxes. When users add contact groups to messages, Outlook expands the memberships to create individual recipients. Exchange Online only sees the individual recipients.
If a message containing sensitive information are delivered to incorrect recipients, senders can attempt to recall the message. However, the recall feature doesn’t work for external recipients. Once a message leaves the tenant, all control is lost.
Protecting Content
Fortunately, Microsoft 365 tenants licensed for Purview information protection can apply sensitivity labels to email and attachments to prevent unauthorized recipients from reading message content. Chapter 19 of Office 365 for IT Pros includes extensive coverage of the rights-management-based encryption used with sensitivity labels. Essentially, if a recipient has not been granted the right to access protected content, they can’t see it. Protection extends to message attachments too.
It’s always embarrassing when confidential material gets into the wrong hands either deliberately or through a user mistake. Sensitivity labels are integrated into all Outlook and Office applications, but their implementation requires substantial planning and deployment effort, including user education. For instance, will label policies require users to apply a sensitivity label to all email or will the focus of protection be on files (messages with protected attachments inherit protection from the attachments)? There’s lots more to think about, and we hope that chapter 19 helps.
On to Update #119
Only two monthly updates remain for Office 365 for IT Pros (2025 edition). We plan to publish #119 for May 2025 and #120 for June 2025 and then move to the 2026 edition with a tentative publication date of July 1, 2025.
Microsoft is currently pouring massive datacenter and software engineering investment into its AI initiatives. Copilot and agents are the obvious signs of that investment within Microsoft 365. Although costly licenses are required to integrate Microsoft 365 data with Copilot, we’re already seeing the introduction of Pay-as-you-go agents as an alternative payment mechanism. It’s easy to imagine how Microsoft might use similar methods to encourage tenants to adopt AI features within applications more broadly. One thing’s for sure: plenty of change remains to play out within Microsoft 365. Our mission to track, analyze, and document how to manage Microsoft 365 tenants will continue.