Category: News
Conectar excel y lista de sahrepoint
Cordial saludo , quisiera su apoyo con el siguiente problema : debo hacer una lista de SharePoint donde pueda actualizarla cada vez que se crea una fila en el archivo origen que seria un Excel ubicado en la nube, el cual a su vez es alimentado por otros archivos. El Excel que alimenta la lista tiene como 12 columnas con datos como fechas ,nombre ,números ,etc.
Intente con un flujo pero al actualizar vuelve y pone datos q ya se encontraba inicialmente
Cordial saludo , quisiera su apoyo con el siguiente problema : debo hacer una lista de SharePoint donde pueda actualizarla cada vez que se crea una fila en el archivo origen que seria un Excel ubicado en la nube, el cual a su vez es alimentado por otros archivos. El Excel que alimenta la lista tiene como 12 columnas con datos como fechas ,nombre ,números ,etc.Intente con un flujo pero al actualizar vuelve y pone datos q ya se encontraba inicialmente Read More
What’s new in Viva Insights
Updates to Copilot Dashboard
Configurable minimum aggregation threshold
The Copilot Dashboard allows users to filter analysis to a desired group, while hiding results if the selected group does not meet a minimum group size for user privacy. To enable customers with more control in specifying the desired privacy threshold, Viva Insights admins can now configure the minimum group size. The default minimum group size is set at 10 and can be lowered to a minimum of 5.
Copilot assisted hours breakdown by app and activity
Copilot assisted hours enables users to estimate the amount of time employees were assisted using Copilot. Users can now select How do we estimate this? to see a breakdown of the Copilot actions that contributed to the hours assisted, and can use the insights to better understand how the total hours assisted is calculated.
Date ranges
Specific date ranges that represent the time period of analysis have been added to the Copilot dashboard.
Microsoft 365 Copilot metrics now available in the metric library in Advanced insights
We’ve added the Microsoft 365 Copilot metrics to the metric library in Advanced insights. As a result, we’re removing the checkbox in the person query that lets analysts add the metrics to their person query. Analysts can now find these metrics in the metric library and in the “add metrics” step in a person query under the “Microsoft 365 Copilot” section.
Meeting cost and quality in the Viva Insights Teams app
With this set of new features, employees can improve meeting time for their colleagues or themselves, and managers and leaders can understand the business case for balancing meeting cost and quality within their organizations.
Each user can choose whether to view meeting cost as hours or currency, and they can edit those settings in the Viva Insights app. Admins can also adjust this setting for others.
Meeting cost and quality report
Eligible managers in Viva Insights will see a report about how much time their team spends in meetings and what share of it goes to high-cost large or long recurring meetings. Reviewing just one or two high-cost meetings can help many others get back their time.
“Like” button
Managers can show other people in their organization if they like the idea of reviewing meetings to balance meeting cost with meeting quality by selecting the Like button. When they do, they’ll be added to the list of people who have liked the scenario, and other Viva Insights users in the company may see their name or picture on related content. If the manager changes their mind, they can select the Like button again.
Meeting review card
The meeting review card is available for both managers and non-managers. The card has two faces: Meetings you organized, and Meetings you’re attending. The meetings I’ve organized side presents opportunities to improve meeting time for your colleagues, and the meetings I’m attending side presents opportunities to improve meeting time for myself. Users can see meeting insights, edit the meeting or their RSVP, or simply mark the meeting as “reviewed” to manage the list.
Meeting compose nudge
The meeting compose nudge encourages users to pay attention to the duration, frequency, and invitee list for high-cost meetings. When a user creates a new meeting in Outlook, it can trigger the infobar message to let the user know when the meeting cost (duration x frequency x invitees) is getting high.
The user can expand the message to open the Viva Insights add-in, which offers actionable suggestions. Accepting suggestions to reduce frequency or shorten duration will immediately update the invitation with a new, less costly configuration.
Viva Feature Access Management
If for any reason meeting cost features aren’t a good fit for some Viva Insights users, admins are able to toggle these features for groups or individuals using Viva Feature Access Management.
Data egress with Microsoft Graph Data Connect
We’re excited to announce the public preview release of Viva Insights data egress with partition support via Microsoft Graph Data Connect (MGDC). Customers can now export Viva Insights data (e.g., computed metrics, imported attributes) from any partition, using flexible queries that also support our PBI templates, into Azure storage. This feature enables customers to build custom analytical solutions by exporting and integrating Viva Insights data with external data or applications. They can integrate insights into business applications like CRM or perform more comprehensive analyses for purposes like workspace planning.
The MGDC export solution is scalable and secure, with the following benefits:
It allows for seamless data access at scale with integrations to the Azure toolchain to enable an accelerated path to insights.
It empowers administrators to review and explicitly consent to the types and amounts of data that applications may consume.
It alleviates concerns and allows organizations to establish detailed data governance policies about how sensitive data is handled, keeping customer data within a single, trusted service boundary.
Learn more about data egress via MGDC.
View Power BI templates in the advanced insights web app
We’re proud to announce the release of a new way to view Power BI templates in the advanced insights web app, leveraging Power BI embedded. With this new option, analysts no longer have to set up Power BI templates in Power BI Desktop, and can instead view them directly in the web app.
After successfully running a Power BI template query, analysts will find a new option to View it in the Query results page, along with the current Data export options, like download .csv.
Upon selecting View, a fully interactive Power BI template is opened. Analysts can navigate across the different pages in the report using the navigation menu and use all the features already available in our Power BI templates, like selecting the employee attributes to view and filter the report by web app.
Users with the Insights Analyst role can view Power BI templates in the advanced insights web app.
New out-of-the-box leader reports
New leader deep-dive reports in Viva Insights focus on customers, business operations, and agility. You can find these reports under Team insights in the Viva Insights app in Teams and on the web.
With these reports, leaders can view a variety of metrics and suggested actions focused on specific business outcomes. Leaders can further drill down into the insights with custom filters such as time periods and breakdowns by group.
The new reports include:
External focus
This report helps leaders understand how employees are managing external relationships, and how different parts of the company may have been impacted by business shifts.
This report can help leaders improve their strategies for communicating and collaborating with external groups. And for groups with increased external engagement, these insights can help leaders ensure these engagements don’t come at the expense of increased after-hours work.
New hire onboarding and integration
The New hire onboarding and integration report helps leaders understand the onboarding experience of new hires as well as the transition for employees who’ve started out in a new role within the company. The report also identifies opportunities to improve the onboarding and professional development experience.
Because research shows it takes new employees 12 months on average to reach their full performance potential, this report focuses on the entire 12-month period a new hire is learning, connecting, and developing in their new role.
This report can help leaders answer the following questions:
How are new hires developing their network, and how fast are they integrating into the organization’s network?
Are new hires getting the 1:1 coaching and support from their managers that they need?
Is the organization sufficiently encouraging new hires and employees to set aside time for learning and training?
Learn more about the new reports.
Microsoft Tech Community – Latest Blogs –Read More
plz help me, worm gear was not generated
The worm gear turns in the direction of the base axis rotationThe worm gear turns in the direction of the base axis rotation The worm gear turns in the direction of the base axis rotation #gear #worm gear #matlab MATLAB Answers — New Questions
MATLab does not solve for my variable and only solves the root of the equation
Hello, I’m new to MATlab, here is the code and the equation:
syms a H Q x y z b c d e f g h
eqn = x + y*a + z*H + b*a^2 + c*H^2 + d*a^3 + e*H^3 + f*a*H + g*a^2*H + h*a*H^2 == Q;
solutions = solve(eqn, a)
variables x y z b c d e f g and h are all constants but they are long numbers so I decided to write them like this. I would like MATlab to solve for a but it just gives me the root of the equation which is useless to me. I even tried replacing the other variables like Q and H with constant to no avail. Even with the only variable being a MATlab still solves for roots instead for a…Hello, I’m new to MATlab, here is the code and the equation:
syms a H Q x y z b c d e f g h
eqn = x + y*a + z*H + b*a^2 + c*H^2 + d*a^3 + e*H^3 + f*a*H + g*a^2*H + h*a*H^2 == Q;
solutions = solve(eqn, a)
variables x y z b c d e f g and h are all constants but they are long numbers so I decided to write them like this. I would like MATlab to solve for a but it just gives me the root of the equation which is useless to me. I even tried replacing the other variables like Q and H with constant to no avail. Even with the only variable being a MATlab still solves for roots instead for a… Hello, I’m new to MATlab, here is the code and the equation:
syms a H Q x y z b c d e f g h
eqn = x + y*a + z*H + b*a^2 + c*H^2 + d*a^3 + e*H^3 + f*a*H + g*a^2*H + h*a*H^2 == Q;
solutions = solve(eqn, a)
variables x y z b c d e f g and h are all constants but they are long numbers so I decided to write them like this. I would like MATlab to solve for a but it just gives me the root of the equation which is useless to me. I even tried replacing the other variables like Q and H with constant to no avail. Even with the only variable being a MATlab still solves for roots instead for a… solving for root instead for variable MATLAB Answers — New Questions
How can I convert my matlab code into python?
close all;
clear all;
clc;
Datafiles = fileDatastore("temp_summary.12*.txt","ReadFcn",@readMonth,"UniformRead",true);
dataAll = readall(Datafiles);
dataAll.Year = year(dataAll.Day);
dataAll.Month = month(dataAll.Day);
dataAll.DD = day(dataAll.Day);
LY = (dataAll.Month(:)==2 & dataAll.DD(:)==29);
dataAll(LY,:) = [];
% Unstack variables
minT_tbl = unstack(dataAll,"MinT","Year","GroupingVariables", ["Month","DD"],"VariableNamingRule","preserve")
maxT_tbl = unstack(dataAll,"MaxT","Year","GroupingVariables", ["Month","DD"],"VariableNamingRule","preserve")
yrs =str2double(minT_tbl.Properties.VariableNames(3:end))’;
% find min
[Tmin,idxMn] = min(minT_tbl{:,3:end},[],2,’omitnan’);
Tmin_yr = yrs(idxMn);
% find max
[Tmax,idxMx] = max(maxT_tbl{:,3:end},[],2,’omitnan’);
Tmax_yr = yrs(idxMx);
% find low high
[lowTMax,idxMx] = min(maxT_tbl{:,3:end},[],2,’omitnan’);
LowTMax_yr = yrs(idxMx);
% find high low
[highlowTMn,idxMn] = max(minT_tbl{:,3:end},[],2,’omitnan’);
HighLowT_yr = yrs(idxMn);
% find avg high
AvgTMx = round(mean(table2array(maxT_tbl(:,3:end)),2,’omitnan’));
% find avg low
AvgTMn = round(mean(table2array(minT_tbl(:,3:end)),2,’omitnan’));
% Results
tempTbl = [maxT_tbl(:,["Month","DD"]), table(Tmax,Tmax_yr,AvgTMx,lowTMax,LowTMax_yr,Tmin,Tmin_yr,AvgTMn,highlowTMn,HighLowT_yr)]
tempTbl2 = splitvars(tempTbl)
FID = fopen(‘Meda 12 Temperature Climatology.txt’,’w’);
report_date = datetime(‘now’,’format’,’yyyy-MM-dd HH:MM’);
fprintf(FID,’Meda 12 Temperature Climatology at %s n’, report_date);
fprintf(FID,"Month DD Temp Max (°F) Tmax_yr AvgTMax (°F) lowTMax (°F) LowTMax_yr TempMin (°F) TMin_yr AvgTMin (°F) HighlowTMin (°F) HighlowT_yr n");
fprintf(FID,’%3d %6d %7d %14d %11d %11d %15d %11d %13d %10d %13d %17d n’, tempTbl2{:,1:end}’);
fclose(FID);
winopen(‘Meda 12 Temperature Climatology.txt’)
function Tbl = readMonth(filename)
opts = detectImportOptions(filename);
opts.ConsecutiveDelimitersRule = ‘join’;
opts.MissingRule = ‘omitvar’;
opts = setvartype(opts,’double’);
opts.VariableNames = ["Day","MaxT","MinT","AvgT"];
Tbl = readtable(filename,opts);
Tbl = standardizeMissing(Tbl,{999,’N/A’},"DataVariables",{‘MaxT’,’MinT’,’AvgT’});
Tbl = standardizeMissing(Tbl,{-99,’N/A’},"DataVariables",{‘MaxT’,’MinT’,’AvgT’});
[~,basename] = fileparts(filename);
% use the base file name, not the full file name:
d = str2double(extract(basename,digitsPattern));
if ~leapyear(d(3)) && d(2) == 2 % February of a non-leap-year
Tbl(Tbl.Day == 29,:) = []; % remove the 29th day data, if any
end
Tbl.Day = datetime(d(3),d(2),Tbl.Day);
end
function tf = leapyear(y)
if mod(y,4) % year is not divisible by 4
tf = false; % it is a common year
elseif mod(y,100) % year is not divisible by 100
tf = true; % it is a leap year
elseif mod(y,400) % year is not divisible by 400
tf = false; % it is a common year
else
tf = true; % it is a leap year
end
endclose all;
clear all;
clc;
Datafiles = fileDatastore("temp_summary.12*.txt","ReadFcn",@readMonth,"UniformRead",true);
dataAll = readall(Datafiles);
dataAll.Year = year(dataAll.Day);
dataAll.Month = month(dataAll.Day);
dataAll.DD = day(dataAll.Day);
LY = (dataAll.Month(:)==2 & dataAll.DD(:)==29);
dataAll(LY,:) = [];
% Unstack variables
minT_tbl = unstack(dataAll,"MinT","Year","GroupingVariables", ["Month","DD"],"VariableNamingRule","preserve")
maxT_tbl = unstack(dataAll,"MaxT","Year","GroupingVariables", ["Month","DD"],"VariableNamingRule","preserve")
yrs =str2double(minT_tbl.Properties.VariableNames(3:end))’;
% find min
[Tmin,idxMn] = min(minT_tbl{:,3:end},[],2,’omitnan’);
Tmin_yr = yrs(idxMn);
% find max
[Tmax,idxMx] = max(maxT_tbl{:,3:end},[],2,’omitnan’);
Tmax_yr = yrs(idxMx);
% find low high
[lowTMax,idxMx] = min(maxT_tbl{:,3:end},[],2,’omitnan’);
LowTMax_yr = yrs(idxMx);
% find high low
[highlowTMn,idxMn] = max(minT_tbl{:,3:end},[],2,’omitnan’);
HighLowT_yr = yrs(idxMn);
% find avg high
AvgTMx = round(mean(table2array(maxT_tbl(:,3:end)),2,’omitnan’));
% find avg low
AvgTMn = round(mean(table2array(minT_tbl(:,3:end)),2,’omitnan’));
% Results
tempTbl = [maxT_tbl(:,["Month","DD"]), table(Tmax,Tmax_yr,AvgTMx,lowTMax,LowTMax_yr,Tmin,Tmin_yr,AvgTMn,highlowTMn,HighLowT_yr)]
tempTbl2 = splitvars(tempTbl)
FID = fopen(‘Meda 12 Temperature Climatology.txt’,’w’);
report_date = datetime(‘now’,’format’,’yyyy-MM-dd HH:MM’);
fprintf(FID,’Meda 12 Temperature Climatology at %s n’, report_date);
fprintf(FID,"Month DD Temp Max (°F) Tmax_yr AvgTMax (°F) lowTMax (°F) LowTMax_yr TempMin (°F) TMin_yr AvgTMin (°F) HighlowTMin (°F) HighlowT_yr n");
fprintf(FID,’%3d %6d %7d %14d %11d %11d %15d %11d %13d %10d %13d %17d n’, tempTbl2{:,1:end}’);
fclose(FID);
winopen(‘Meda 12 Temperature Climatology.txt’)
function Tbl = readMonth(filename)
opts = detectImportOptions(filename);
opts.ConsecutiveDelimitersRule = ‘join’;
opts.MissingRule = ‘omitvar’;
opts = setvartype(opts,’double’);
opts.VariableNames = ["Day","MaxT","MinT","AvgT"];
Tbl = readtable(filename,opts);
Tbl = standardizeMissing(Tbl,{999,’N/A’},"DataVariables",{‘MaxT’,’MinT’,’AvgT’});
Tbl = standardizeMissing(Tbl,{-99,’N/A’},"DataVariables",{‘MaxT’,’MinT’,’AvgT’});
[~,basename] = fileparts(filename);
% use the base file name, not the full file name:
d = str2double(extract(basename,digitsPattern));
if ~leapyear(d(3)) && d(2) == 2 % February of a non-leap-year
Tbl(Tbl.Day == 29,:) = []; % remove the 29th day data, if any
end
Tbl.Day = datetime(d(3),d(2),Tbl.Day);
end
function tf = leapyear(y)
if mod(y,4) % year is not divisible by 4
tf = false; % it is a common year
elseif mod(y,100) % year is not divisible by 100
tf = true; % it is a leap year
elseif mod(y,400) % year is not divisible by 400
tf = false; % it is a common year
else
tf = true; % it is a leap year
end
end close all;
clear all;
clc;
Datafiles = fileDatastore("temp_summary.12*.txt","ReadFcn",@readMonth,"UniformRead",true);
dataAll = readall(Datafiles);
dataAll.Year = year(dataAll.Day);
dataAll.Month = month(dataAll.Day);
dataAll.DD = day(dataAll.Day);
LY = (dataAll.Month(:)==2 & dataAll.DD(:)==29);
dataAll(LY,:) = [];
% Unstack variables
minT_tbl = unstack(dataAll,"MinT","Year","GroupingVariables", ["Month","DD"],"VariableNamingRule","preserve")
maxT_tbl = unstack(dataAll,"MaxT","Year","GroupingVariables", ["Month","DD"],"VariableNamingRule","preserve")
yrs =str2double(minT_tbl.Properties.VariableNames(3:end))’;
% find min
[Tmin,idxMn] = min(minT_tbl{:,3:end},[],2,’omitnan’);
Tmin_yr = yrs(idxMn);
% find max
[Tmax,idxMx] = max(maxT_tbl{:,3:end},[],2,’omitnan’);
Tmax_yr = yrs(idxMx);
% find low high
[lowTMax,idxMx] = min(maxT_tbl{:,3:end},[],2,’omitnan’);
LowTMax_yr = yrs(idxMx);
% find high low
[highlowTMn,idxMn] = max(minT_tbl{:,3:end},[],2,’omitnan’);
HighLowT_yr = yrs(idxMn);
% find avg high
AvgTMx = round(mean(table2array(maxT_tbl(:,3:end)),2,’omitnan’));
% find avg low
AvgTMn = round(mean(table2array(minT_tbl(:,3:end)),2,’omitnan’));
% Results
tempTbl = [maxT_tbl(:,["Month","DD"]), table(Tmax,Tmax_yr,AvgTMx,lowTMax,LowTMax_yr,Tmin,Tmin_yr,AvgTMn,highlowTMn,HighLowT_yr)]
tempTbl2 = splitvars(tempTbl)
FID = fopen(‘Meda 12 Temperature Climatology.txt’,’w’);
report_date = datetime(‘now’,’format’,’yyyy-MM-dd HH:MM’);
fprintf(FID,’Meda 12 Temperature Climatology at %s n’, report_date);
fprintf(FID,"Month DD Temp Max (°F) Tmax_yr AvgTMax (°F) lowTMax (°F) LowTMax_yr TempMin (°F) TMin_yr AvgTMin (°F) HighlowTMin (°F) HighlowT_yr n");
fprintf(FID,’%3d %6d %7d %14d %11d %11d %15d %11d %13d %10d %13d %17d n’, tempTbl2{:,1:end}’);
fclose(FID);
winopen(‘Meda 12 Temperature Climatology.txt’)
function Tbl = readMonth(filename)
opts = detectImportOptions(filename);
opts.ConsecutiveDelimitersRule = ‘join’;
opts.MissingRule = ‘omitvar’;
opts = setvartype(opts,’double’);
opts.VariableNames = ["Day","MaxT","MinT","AvgT"];
Tbl = readtable(filename,opts);
Tbl = standardizeMissing(Tbl,{999,’N/A’},"DataVariables",{‘MaxT’,’MinT’,’AvgT’});
Tbl = standardizeMissing(Tbl,{-99,’N/A’},"DataVariables",{‘MaxT’,’MinT’,’AvgT’});
[~,basename] = fileparts(filename);
% use the base file name, not the full file name:
d = str2double(extract(basename,digitsPattern));
if ~leapyear(d(3)) && d(2) == 2 % February of a non-leap-year
Tbl(Tbl.Day == 29,:) = []; % remove the 29th day data, if any
end
Tbl.Day = datetime(d(3),d(2),Tbl.Day);
end
function tf = leapyear(y)
if mod(y,4) % year is not divisible by 4
tf = false; % it is a common year
elseif mod(y,100) % year is not divisible by 100
tf = true; % it is a leap year
elseif mod(y,400) % year is not divisible by 400
tf = false; % it is a common year
else
tf = true; % it is a leap year
end
end python, matlab code MATLAB Answers — New Questions
Even though I finished the course 100% the certification ,progress report and in my courses it shows as 0% , why is it so? the course is “simulink Onramp”
Warning: File "/tmp/simulinkselfpaced/SimulinkOnramp.slx" is missing, which will prevent you from saving this model properly. If the file moved, then close the model and open
Like this text is coming in command window of MatLabWarning: File "/tmp/simulinkselfpaced/SimulinkOnramp.slx" is missing, which will prevent you from saving this model properly. If the file moved, then close the model and open
Like this text is coming in command window of MatLab Warning: File "/tmp/simulinkselfpaced/SimulinkOnramp.slx" is missing, which will prevent you from saving this model properly. If the file moved, then close the model and open
Like this text is coming in command window of MatLab mathworks, course_no_progress_updation MATLAB Answers — New Questions
lsqcurvefit “Function value and YDATA sizes are not equal” for a complicated fitting function
Hi all, I have some experimental data to be fitted to a function that is quite complicated (refer to the attached picture). And I kept getting the message that the function size and YDATA size are not equal. How do I solve this?
clear; clc
load Steady_State_Data.mat % this contains the wavelength of light and absorbance of substrate and sample
% Fundamental constants
h = 4.0135667696*10^-15; % units: eV/ Hz
c = 3*10^8; % SI units
% Clean up of data to select range of values
Absorbance = log10(T_substrate./T_sample);
E = (h*c./(Lambda*10^-9));
e = E >= 0 & E <= 2.0; % returns boolean value of the indices that satisfies the logical condition defined above
A = find(e); % gives indices that are non-zero
N = length(A); % no. of elements that are non-zero
n = length(E) + 1;
% Data for fitting
E_p = E(n-N:167);
Abs = Absorbance(n-N:167);
function F = EM_SS(p, e_p)
for i = 1:numel(e_p)
E_p = e_p(i);
F(i) = p(1)*(2*pi*sqrt(p(4))/E_p)*(1/p(6))*…
(integral(@(E)sech(((E_p – E)./p(6)))*(1 + 10*p(5)*(E – p(3)) + …
126*p(5)^2*(E – p(3))^2)/(1 – exp(-2*pi*sqrt(p(4)/(E – p(3))))), p(3), Inf, ‘ArrayValued’, 1)) + …
p(2)*(2*pi*p(4)^3/2)*1/p(6)*(…
(1/1^3)*sech((E_p – p(3) + p(4)/1^2)./p(6)) + …
(1/2^3)*sech((E_p – p(3) + p(4)/2^2)./p(6)) + …
(1/3^3)*sech((E_p – p(3) + p(4)/3^2)./p(6)) + …
(1/4^3)*sech((E_p – p(3) + p(4)/4^2)./p(6)) + …
(1/5^3)*sech((E_p – p(3) + p(4)/5^2)./p(6)) + …
(1/6^3)*sech((E_p – p(3) + p(4)/6^2)./p(6)) + …
(1/7^3)*sech((E_p – p(3) + p(4)/7^2)./p(6)));
end
end
% Initial parameter guess and bounds
lb = []; ub = [];
p0 = [0.13 0.1 1.6 0.05 3 1]; % refer to the next line for their order
% p0 = [A1 A2 Eg Eb R g]
% choose between different algorithm of lsqcurvefit (3C1, comment those lines that are not choosen, if not, matlab will take the last line of "optim_lsq" by default)
optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘levenberg-marquardt’);
% optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘trust-region-reflective’);
% optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘interior-point’);
% fminunc
% optim_fminunc = optimsoptions(‘fminunc’, ‘Algorithm’, ‘Quasi-Newton’);
% solver
[p, resnorm, residual, exitflag, output, jacobian] = lsqcurvefit(@EM_SS, p0, E_p, Abs);
% p = lsqcurvefit(@EM_SS, p0, E_p, Abs);
% Plot command
plot(E_p, Abs, ‘o’)
hold on
% plot(E_p, p(1)*(2*pi*sqrt(p(4))/E_p)*(1/p(6))*…
% (integral(@(E)sech(((E_p – E)./p(6)))*(1 + 10*p(5)*(E – p(3)) + …
% 126*p(5)^2*(E – p(3))^2)/(1 – exp(-2*pi*sqrt(p(4)/(E – p(3))))), p(3), Inf, ‘ArrayValued’, 1)) + …
% p(2)*(2*pi*p(4)^3/2)*1/p(6)*(…
% (1/1^3)*sech((E_p – p(3) + p(4)/1^2)./p(6)) + …
% (1/2^3)*sech((E_p – p(3) + p(4)/2^2)./p(6)) + …
% (1/3^3)*sech((E_p – p(3) + p(4)/3^2)./p(6)) + …
% (1/4^3)*sech((E_p – p(3) + p(4)/4^2)./p(6)) + …
% (1/5^3)*sech((E_p – p(3) + p(4)/5^2)./p(6)) + …
% (1/6^3)*sech((E_p – p(3) + p(4)/6^2)./p(6)) + …
% (1/7^3)*sech((E_p – p(3) + p(4)/7^2)./p(6))))
plot(E_p, EM_SS(E_p, p))
xlabel(‘Probe energy (eV)’)
ylabel(‘Absorbance.O.D’)
legend(‘Experimental Data’, ‘Fitted Curve’)
hold off
% Parameter values (refer to command window)
p1 = p(1,1);
p2 = p(1,2);
p3 = p(1,3);
p4 = p(1,4);
p5 = p(1,5);
p6 = p(1,6);
X1 = [‘ A1 = ‘, num2str(p1)];
X2 = [‘ A2 = ‘, num2str(p2)];
X3 = [‘ Eg = ‘, num2str(p3)];
X4 = [‘ Eb = ‘, num2str(p4)];
X5 = [‘ R = ‘, num2str(p5)];
X6 = [‘ g = ‘, num2str(p6)];
disp(X1);
disp(X2);
disp(X3);
disp(X4);
disp(X5);
disp(X6);Hi all, I have some experimental data to be fitted to a function that is quite complicated (refer to the attached picture). And I kept getting the message that the function size and YDATA size are not equal. How do I solve this?
clear; clc
load Steady_State_Data.mat % this contains the wavelength of light and absorbance of substrate and sample
% Fundamental constants
h = 4.0135667696*10^-15; % units: eV/ Hz
c = 3*10^8; % SI units
% Clean up of data to select range of values
Absorbance = log10(T_substrate./T_sample);
E = (h*c./(Lambda*10^-9));
e = E >= 0 & E <= 2.0; % returns boolean value of the indices that satisfies the logical condition defined above
A = find(e); % gives indices that are non-zero
N = length(A); % no. of elements that are non-zero
n = length(E) + 1;
% Data for fitting
E_p = E(n-N:167);
Abs = Absorbance(n-N:167);
function F = EM_SS(p, e_p)
for i = 1:numel(e_p)
E_p = e_p(i);
F(i) = p(1)*(2*pi*sqrt(p(4))/E_p)*(1/p(6))*…
(integral(@(E)sech(((E_p – E)./p(6)))*(1 + 10*p(5)*(E – p(3)) + …
126*p(5)^2*(E – p(3))^2)/(1 – exp(-2*pi*sqrt(p(4)/(E – p(3))))), p(3), Inf, ‘ArrayValued’, 1)) + …
p(2)*(2*pi*p(4)^3/2)*1/p(6)*(…
(1/1^3)*sech((E_p – p(3) + p(4)/1^2)./p(6)) + …
(1/2^3)*sech((E_p – p(3) + p(4)/2^2)./p(6)) + …
(1/3^3)*sech((E_p – p(3) + p(4)/3^2)./p(6)) + …
(1/4^3)*sech((E_p – p(3) + p(4)/4^2)./p(6)) + …
(1/5^3)*sech((E_p – p(3) + p(4)/5^2)./p(6)) + …
(1/6^3)*sech((E_p – p(3) + p(4)/6^2)./p(6)) + …
(1/7^3)*sech((E_p – p(3) + p(4)/7^2)./p(6)));
end
end
% Initial parameter guess and bounds
lb = []; ub = [];
p0 = [0.13 0.1 1.6 0.05 3 1]; % refer to the next line for their order
% p0 = [A1 A2 Eg Eb R g]
% choose between different algorithm of lsqcurvefit (3C1, comment those lines that are not choosen, if not, matlab will take the last line of "optim_lsq" by default)
optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘levenberg-marquardt’);
% optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘trust-region-reflective’);
% optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘interior-point’);
% fminunc
% optim_fminunc = optimsoptions(‘fminunc’, ‘Algorithm’, ‘Quasi-Newton’);
% solver
[p, resnorm, residual, exitflag, output, jacobian] = lsqcurvefit(@EM_SS, p0, E_p, Abs);
% p = lsqcurvefit(@EM_SS, p0, E_p, Abs);
% Plot command
plot(E_p, Abs, ‘o’)
hold on
% plot(E_p, p(1)*(2*pi*sqrt(p(4))/E_p)*(1/p(6))*…
% (integral(@(E)sech(((E_p – E)./p(6)))*(1 + 10*p(5)*(E – p(3)) + …
% 126*p(5)^2*(E – p(3))^2)/(1 – exp(-2*pi*sqrt(p(4)/(E – p(3))))), p(3), Inf, ‘ArrayValued’, 1)) + …
% p(2)*(2*pi*p(4)^3/2)*1/p(6)*(…
% (1/1^3)*sech((E_p – p(3) + p(4)/1^2)./p(6)) + …
% (1/2^3)*sech((E_p – p(3) + p(4)/2^2)./p(6)) + …
% (1/3^3)*sech((E_p – p(3) + p(4)/3^2)./p(6)) + …
% (1/4^3)*sech((E_p – p(3) + p(4)/4^2)./p(6)) + …
% (1/5^3)*sech((E_p – p(3) + p(4)/5^2)./p(6)) + …
% (1/6^3)*sech((E_p – p(3) + p(4)/6^2)./p(6)) + …
% (1/7^3)*sech((E_p – p(3) + p(4)/7^2)./p(6))))
plot(E_p, EM_SS(E_p, p))
xlabel(‘Probe energy (eV)’)
ylabel(‘Absorbance.O.D’)
legend(‘Experimental Data’, ‘Fitted Curve’)
hold off
% Parameter values (refer to command window)
p1 = p(1,1);
p2 = p(1,2);
p3 = p(1,3);
p4 = p(1,4);
p5 = p(1,5);
p6 = p(1,6);
X1 = [‘ A1 = ‘, num2str(p1)];
X2 = [‘ A2 = ‘, num2str(p2)];
X3 = [‘ Eg = ‘, num2str(p3)];
X4 = [‘ Eb = ‘, num2str(p4)];
X5 = [‘ R = ‘, num2str(p5)];
X6 = [‘ g = ‘, num2str(p6)];
disp(X1);
disp(X2);
disp(X3);
disp(X4);
disp(X5);
disp(X6); Hi all, I have some experimental data to be fitted to a function that is quite complicated (refer to the attached picture). And I kept getting the message that the function size and YDATA size are not equal. How do I solve this?
clear; clc
load Steady_State_Data.mat % this contains the wavelength of light and absorbance of substrate and sample
% Fundamental constants
h = 4.0135667696*10^-15; % units: eV/ Hz
c = 3*10^8; % SI units
% Clean up of data to select range of values
Absorbance = log10(T_substrate./T_sample);
E = (h*c./(Lambda*10^-9));
e = E >= 0 & E <= 2.0; % returns boolean value of the indices that satisfies the logical condition defined above
A = find(e); % gives indices that are non-zero
N = length(A); % no. of elements that are non-zero
n = length(E) + 1;
% Data for fitting
E_p = E(n-N:167);
Abs = Absorbance(n-N:167);
function F = EM_SS(p, e_p)
for i = 1:numel(e_p)
E_p = e_p(i);
F(i) = p(1)*(2*pi*sqrt(p(4))/E_p)*(1/p(6))*…
(integral(@(E)sech(((E_p – E)./p(6)))*(1 + 10*p(5)*(E – p(3)) + …
126*p(5)^2*(E – p(3))^2)/(1 – exp(-2*pi*sqrt(p(4)/(E – p(3))))), p(3), Inf, ‘ArrayValued’, 1)) + …
p(2)*(2*pi*p(4)^3/2)*1/p(6)*(…
(1/1^3)*sech((E_p – p(3) + p(4)/1^2)./p(6)) + …
(1/2^3)*sech((E_p – p(3) + p(4)/2^2)./p(6)) + …
(1/3^3)*sech((E_p – p(3) + p(4)/3^2)./p(6)) + …
(1/4^3)*sech((E_p – p(3) + p(4)/4^2)./p(6)) + …
(1/5^3)*sech((E_p – p(3) + p(4)/5^2)./p(6)) + …
(1/6^3)*sech((E_p – p(3) + p(4)/6^2)./p(6)) + …
(1/7^3)*sech((E_p – p(3) + p(4)/7^2)./p(6)));
end
end
% Initial parameter guess and bounds
lb = []; ub = [];
p0 = [0.13 0.1 1.6 0.05 3 1]; % refer to the next line for their order
% p0 = [A1 A2 Eg Eb R g]
% choose between different algorithm of lsqcurvefit (3C1, comment those lines that are not choosen, if not, matlab will take the last line of "optim_lsq" by default)
optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘levenberg-marquardt’);
% optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘trust-region-reflective’);
% optim_lsq = optimoptions(‘lsqcurvefit’, ‘Algorithm’, ‘interior-point’);
% fminunc
% optim_fminunc = optimsoptions(‘fminunc’, ‘Algorithm’, ‘Quasi-Newton’);
% solver
[p, resnorm, residual, exitflag, output, jacobian] = lsqcurvefit(@EM_SS, p0, E_p, Abs);
% p = lsqcurvefit(@EM_SS, p0, E_p, Abs);
% Plot command
plot(E_p, Abs, ‘o’)
hold on
% plot(E_p, p(1)*(2*pi*sqrt(p(4))/E_p)*(1/p(6))*…
% (integral(@(E)sech(((E_p – E)./p(6)))*(1 + 10*p(5)*(E – p(3)) + …
% 126*p(5)^2*(E – p(3))^2)/(1 – exp(-2*pi*sqrt(p(4)/(E – p(3))))), p(3), Inf, ‘ArrayValued’, 1)) + …
% p(2)*(2*pi*p(4)^3/2)*1/p(6)*(…
% (1/1^3)*sech((E_p – p(3) + p(4)/1^2)./p(6)) + …
% (1/2^3)*sech((E_p – p(3) + p(4)/2^2)./p(6)) + …
% (1/3^3)*sech((E_p – p(3) + p(4)/3^2)./p(6)) + …
% (1/4^3)*sech((E_p – p(3) + p(4)/4^2)./p(6)) + …
% (1/5^3)*sech((E_p – p(3) + p(4)/5^2)./p(6)) + …
% (1/6^3)*sech((E_p – p(3) + p(4)/6^2)./p(6)) + …
% (1/7^3)*sech((E_p – p(3) + p(4)/7^2)./p(6))))
plot(E_p, EM_SS(E_p, p))
xlabel(‘Probe energy (eV)’)
ylabel(‘Absorbance.O.D’)
legend(‘Experimental Data’, ‘Fitted Curve’)
hold off
% Parameter values (refer to command window)
p1 = p(1,1);
p2 = p(1,2);
p3 = p(1,3);
p4 = p(1,4);
p5 = p(1,5);
p6 = p(1,6);
X1 = [‘ A1 = ‘, num2str(p1)];
X2 = [‘ A2 = ‘, num2str(p2)];
X3 = [‘ Eg = ‘, num2str(p3)];
X4 = [‘ Eb = ‘, num2str(p4)];
X5 = [‘ R = ‘, num2str(p5)];
X6 = [‘ g = ‘, num2str(p6)];
disp(X1);
disp(X2);
disp(X3);
disp(X4);
disp(X5);
disp(X6); curve fitting MATLAB Answers — New Questions
Conditional Formatting Help with Percentages
Hi there,
I’m trying to do icon set conditional formatting on percentages in Excel. My ideal formatting would be a red icon for anything over 15%, yellow icon for anything between 10-14.9%, and green icon for anything less than 10%. Below is what I’ve selected in my parameters, but it’s not giving me my desired formatting. Can anyone assist me?
This is what is happening when I use the above parameters:
Hi there, I’m trying to do icon set conditional formatting on percentages in Excel. My ideal formatting would be a red icon for anything over 15%, yellow icon for anything between 10-14.9%, and green icon for anything less than 10%. Below is what I’ve selected in my parameters, but it’s not giving me my desired formatting. Can anyone assist me? This is what is happening when I use the above parameters: Read More
Screen artifacts, lines, and blurry text when connecting from macOS Microsoft Remote Desktop clients
We’re having many users reporting that they’re seeing screen artifacts, lines, and blurry fonts in their Windows applications. The issue appeared to have started recently, around the June 4, 2024. It seems to coincide with the latest update pushed by Microsoft, Remote Desktop Services SxS Network Stack:
This issue is occurring on Windows 10 and Windows 11 Azure Virtual Desktop machines and Windows 365 (Cloud PC), running Windows 10 and Windows 11 as well.
Users are also running Microsoft Remote Desktop version 10.9.7. Issue also occurred on users that were still running version 10.9.6.
There are several other folks in the Azure Virtual Desktop feedback forum reporting similar issues:
Vertical Lines appear for Azure Virtuals – Microsoft Community Hub
microsoft remote desktop macos graphic issue – Microsoft Community Hub
Microsoft, please get on this. I’ve opened a ticket in the Azure Help + Support interface.
We’re having many users reporting that they’re seeing screen artifacts, lines, and blurry fonts in their Windows applications. The issue appeared to have started recently, around the June 4, 2024. It seems to coincide with the latest update pushed by Microsoft, Remote Desktop Services SxS Network Stack: This issue is occurring on Windows 10 and Windows 11 Azure Virtual Desktop machines and Windows 365 (Cloud PC), running Windows 10 and Windows 11 as well. Users are also running Microsoft Remote Desktop version 10.9.7. Issue also occurred on users that were still running version 10.9.6.There are several other folks in the Azure Virtual Desktop feedback forum reporting similar issues:Vertical Lines appear for Azure Virtuals – Microsoft Community Hubmicrosoft remote desktop macos graphic issue – Microsoft Community HubMicrosoft, please get on this. I’ve opened a ticket in the Azure Help + Support interface. Read More
Power Platform & Dynamics 365 Newsletter – June 2024
June 2024 Edition
The newsletter is attached below.
Welcome to the June 2024 Edition – A large section is dedicated to Microsoft Build!
Power Platform and Dynamics 365 CE Newsletter!
As usual we have a lot of news and highlights to catch up on and plan!
No time to read it all, here are some quick reading recommendations:
Microsoft Build : Everything to know
Upcoming Microsoft events
Copilot for Sales extensibility News.
Review Power Apps, Dataverse, Copilot product updates.
Thanks & regards.
Power Platform & D365 Newsletter Team
—
Premier Support for Partners (PSfP) and Advanced Support for Partners (ASfP) are paid partner offerings at Microsoft that provide unmatched value through a wide range of Partner benefits including account management, direct-from-Microsoft advisory consultations, the highest level of reactive support available including up to 15-minute response times on critical cases, and coverage across cloud, hybrid, and on-prem.
Please review these resources to learn more and consider booking a meeting to speak directly with our teams for a better understanding of the value-added benefits of PSfP and ASfP.
Book a meeting with a PSfP Specialist
Book a meeting with an ASfP Evangelist
Visit the ASfP Website
Download the ASfP Fact Sheet
View the ASfP Impact Slide
Stop by the ASfP Partner Community
June 2024 Edition
The newsletter is attached below.
Welcome to the June 2024 Edition – A large section is dedicated to Microsoft Build!
Power Platform and Dynamics 365 CE Newsletter!
As usual we have a lot of news and highlights to catch up on and plan!
No time to read it all, here are some quick reading recommendations:
Microsoft Build : Everything to know
Upcoming Microsoft events
Copilot for Sales extensibility News.
Review Power Apps, Dataverse, Copilot product updates.
Thanks & regards.
Power Platform & D365 Newsletter Team
—
Premier Support for Partners (PSfP) and Advanced Support for Partners (ASfP) are paid partner offerings at Microsoft that provide unmatched value through a wide range of Partner benefits including account management, direct-from-Microsoft advisory consultations, the highest level of reactive support available including up to 15-minute response times on critical cases, and coverage across cloud, hybrid, and on-prem.
Please review these resources to learn more and consider booking a meeting to speak directly with our teams for a better understanding of the value-added benefits of PSfP and ASfP.
Book a meeting with a PSfP Specialist
Visit the PSfP Website
Book a meeting with an ASfP Evangelist
Visit the ASfP Website
Download the ASfP Fact Sheet
View the ASfP Impact Slide
Stop by the ASfP Partner Community
Forwarding only accepted meetings to a MTR resource account
Hello,
I am trying to forward all accepted meeting invites from a user to a specific MTR resource room. I have looked at the documentation but only see a way to forward all invites which the room auto accepts. Is there a way to automate this in poweshell?
Hello, I am trying to forward all accepted meeting invites from a user to a specific MTR resource room. I have looked at the documentation but only see a way to forward all invites which the room auto accepts. Is there a way to automate this in poweshell? Read More
List data validation suggested completions list is not fuctioning correctly in column A:A
Hi,
I’ve noticed Data Validation is not listing suggested completions, in a dropdown list shortened from the original list to include only valid completions, for column A:A only. (It used to).
Inserting a blank column A:A resolves the issue
Unchecking {View, Headings} resolves the issue
Only some users are affected
The user affected has the app based version of Excel through Office365, but others also have exactly that setup, and don’t have difficulties.
The list Data Validation references a named table on another sheet, that way users can extend the valid inputs easily, should they need to.
Why is only the first column affected? And why does inserting a blank column resolve it?
I should add, the cut down allowable completions list is visible for about 1/100th of a second, but only once. Then won’t appear again until you click away and click back.
Also, the dropdown arrow still provides access to the scrollable list in full.
Columns other than A:A on the same sheet have the same {named table, list Data Validation} arrangement and work perfectly.
Search engines suggest I’m not alone. (But then I got accused of hijacking someone else’s thread, so I hightailed it here instead!)
Thanks,
Michael.
Hi, I’ve noticed Data Validation is not listing suggested completions, in a dropdown list shortened from the original list to include only valid completions, for column A:A only. (It used to). Inserting a blank column A:A resolves the issueUnchecking {View, Headings} resolves the issueOnly some users are affected The user affected has the app based version of Excel through Office365, but others also have exactly that setup, and don’t have difficulties. The list Data Validation references a named table on another sheet, that way users can extend the valid inputs easily, should they need to. Why is only the first column affected? And why does inserting a blank column resolve it? I should add, the cut down allowable completions list is visible for about 1/100th of a second, but only once. Then won’t appear again until you click away and click back. Also, the dropdown arrow still provides access to the scrollable list in full. Columns other than A:A on the same sheet have the same {named table, list Data Validation} arrangement and work perfectly. Search engines suggest I’m not alone. (But then I got accused of hijacking someone else’s thread, so I hightailed it here instead!) Thanks, Michael. Read More
Microsoft Business Standard – Manage with PowerShell?
Hi,
Longtime Microsoft 365 admin but PowerShell & Azure newbie here. I have a need to to configure settings that only seem to be configurable via PowerShell (and not available in the Admin center GUI). However, everything I read seems to infer that PowerShell can be used just with Microsoft 365 Enterprise licenses. I would like to know whether PowerShell can be used with an organization that uses Business Basic and Business Standard licenses (Using Azure CloudShell and an Azure storage account)?
Thank you!
Hi, Longtime Microsoft 365 admin but PowerShell & Azure newbie here. I have a need to to configure settings that only seem to be configurable via PowerShell (and not available in the Admin center GUI). However, everything I read seems to infer that PowerShell can be used just with Microsoft 365 Enterprise licenses. I would like to know whether PowerShell can be used with an organization that uses Business Basic and Business Standard licenses (Using Azure CloudShell and an Azure storage account)? Thank you! Read More
Multiple sequences for Neural State-Space Model training and different sampling times
Hi all,
I have some doubts about Neural State-Space Models.
1) I would like to train such a model using different observations (or tests). In other words, I have time sequences measured in different experiments and I would like to use them to train the model. From the examples currently online, I could not figure out how to do this, since it seems to me that the training data are always represented by a single time sequence.
2) Suppose the time sequences I want to train the model with have a sampling time given as d_t. I want to use the Neural State-Space Model that I identify with this data in Simulink. I can do this using just the dedicated Neural State-Space Model block. Suppose, however, that I want to run simulations using this model in Simulink with sample times to my preference. I am aware of rate transition blocks, but can they do the trick for me for this type of problem? In other words, does the Simulink block of the Neural State-Space Model allow me to work with other sampling times, or am I constrained to use the model with sampling times equal to that of the time series with which I have trained the model (thus what has been referred to as d_t)?
Thank you in advance for the support!
Best regards,
MarcoHi all,
I have some doubts about Neural State-Space Models.
1) I would like to train such a model using different observations (or tests). In other words, I have time sequences measured in different experiments and I would like to use them to train the model. From the examples currently online, I could not figure out how to do this, since it seems to me that the training data are always represented by a single time sequence.
2) Suppose the time sequences I want to train the model with have a sampling time given as d_t. I want to use the Neural State-Space Model that I identify with this data in Simulink. I can do this using just the dedicated Neural State-Space Model block. Suppose, however, that I want to run simulations using this model in Simulink with sample times to my preference. I am aware of rate transition blocks, but can they do the trick for me for this type of problem? In other words, does the Simulink block of the Neural State-Space Model allow me to work with other sampling times, or am I constrained to use the model with sampling times equal to that of the time series with which I have trained the model (thus what has been referred to as d_t)?
Thank you in advance for the support!
Best regards,
Marco Hi all,
I have some doubts about Neural State-Space Models.
1) I would like to train such a model using different observations (or tests). In other words, I have time sequences measured in different experiments and I would like to use them to train the model. From the examples currently online, I could not figure out how to do this, since it seems to me that the training data are always represented by a single time sequence.
2) Suppose the time sequences I want to train the model with have a sampling time given as d_t. I want to use the Neural State-Space Model that I identify with this data in Simulink. I can do this using just the dedicated Neural State-Space Model block. Suppose, however, that I want to run simulations using this model in Simulink with sample times to my preference. I am aware of rate transition blocks, but can they do the trick for me for this type of problem? In other words, does the Simulink block of the Neural State-Space Model allow me to work with other sampling times, or am I constrained to use the model with sampling times equal to that of the time series with which I have trained the model (thus what has been referred to as d_t)?
Thank you in advance for the support!
Best regards,
Marco neural state-space models, system identification, machine learning, deep learning, reduced order modelling, simulation MATLAB Answers — New Questions
median of grouped frequency data
Given the data below
calculate the median of the data in MATLAB
I have the code below
class_intervals = [420 430; 430 440; 440 450; 450 460; 460 470; 470 480; 480 490; 490 500];
frequencies = [336, 2112, 2336, 1074, 1553, 1336, 736, 85];
% Calculate the cumulative frequencies
cum_frequencies = cumsum(frequencies)
% Calculate the total number of observations
N = sum(frequencies);
% Find the median class (where cumulative frequency exceeds N/2)
median_class_index = find(cum_frequencies >= N/2, 1)
% Extract the lower boundary, frequency, and cumulative frequency of the class before the median class
L = class_intervals(median_class_index, 1) % lower boundary of the median class
f = frequencies(median_class_index) % frequency of the median class
if median_class_index == 1
cf = 0; % cumulative frequency before the median class
else
cf = cum_frequencies(median_class_index – 1) % cumulative frequency before the median class
end
% Calculate the width of the median class interval
h = class_intervals(median_class_index, 2) – class_intervals(median_class_index, 1)
% Calculate the median using the formula
median = L + ((N/2 – cf) / f) * h
However I was wondering if instead of calculating it manually is there any inbuilt function in MATLAB to calculate median of grouped data.Given the data below
calculate the median of the data in MATLAB
I have the code below
class_intervals = [420 430; 430 440; 440 450; 450 460; 460 470; 470 480; 480 490; 490 500];
frequencies = [336, 2112, 2336, 1074, 1553, 1336, 736, 85];
% Calculate the cumulative frequencies
cum_frequencies = cumsum(frequencies)
% Calculate the total number of observations
N = sum(frequencies);
% Find the median class (where cumulative frequency exceeds N/2)
median_class_index = find(cum_frequencies >= N/2, 1)
% Extract the lower boundary, frequency, and cumulative frequency of the class before the median class
L = class_intervals(median_class_index, 1) % lower boundary of the median class
f = frequencies(median_class_index) % frequency of the median class
if median_class_index == 1
cf = 0; % cumulative frequency before the median class
else
cf = cum_frequencies(median_class_index – 1) % cumulative frequency before the median class
end
% Calculate the width of the median class interval
h = class_intervals(median_class_index, 2) – class_intervals(median_class_index, 1)
% Calculate the median using the formula
median = L + ((N/2 – cf) / f) * h
However I was wondering if instead of calculating it manually is there any inbuilt function in MATLAB to calculate median of grouped data. Given the data below
calculate the median of the data in MATLAB
I have the code below
class_intervals = [420 430; 430 440; 440 450; 450 460; 460 470; 470 480; 480 490; 490 500];
frequencies = [336, 2112, 2336, 1074, 1553, 1336, 736, 85];
% Calculate the cumulative frequencies
cum_frequencies = cumsum(frequencies)
% Calculate the total number of observations
N = sum(frequencies);
% Find the median class (where cumulative frequency exceeds N/2)
median_class_index = find(cum_frequencies >= N/2, 1)
% Extract the lower boundary, frequency, and cumulative frequency of the class before the median class
L = class_intervals(median_class_index, 1) % lower boundary of the median class
f = frequencies(median_class_index) % frequency of the median class
if median_class_index == 1
cf = 0; % cumulative frequency before the median class
else
cf = cum_frequencies(median_class_index – 1) % cumulative frequency before the median class
end
% Calculate the width of the median class interval
h = class_intervals(median_class_index, 2) – class_intervals(median_class_index, 1)
% Calculate the median using the formula
median = L + ((N/2 – cf) / f) * h
However I was wondering if instead of calculating it manually is there any inbuilt function in MATLAB to calculate median of grouped data. descriptive statistics MATLAB Answers — New Questions
Shapley values for newff model
Hi there, I trained a BP nerual network using newff function, and want to obtain its Shapley values and swarmchart graph. But I have got the following error:
Code:
P = [2 3 1;3 4 5;1 3 4;4 6 7;2 7 3]’;
T = [1 2 3 4 5];
net=newff(P,T,5,{‘tansig’ ‘purelin’},’trainlm’);
[net,tr]=train(net,P,T);
queryPoint = P(:,1);
explainer1 = shapley(net,P,’QueryPoint’,queryPoint);
Error:
Error using shapley (line 233)
Blackbox model must be a classification model, regression model, or function handle
Error in untitled (line 10)
explainer1 = shapley(net,P,’QueryPoint’,queryPoint);Hi there, I trained a BP nerual network using newff function, and want to obtain its Shapley values and swarmchart graph. But I have got the following error:
Code:
P = [2 3 1;3 4 5;1 3 4;4 6 7;2 7 3]’;
T = [1 2 3 4 5];
net=newff(P,T,5,{‘tansig’ ‘purelin’},’trainlm’);
[net,tr]=train(net,P,T);
queryPoint = P(:,1);
explainer1 = shapley(net,P,’QueryPoint’,queryPoint);
Error:
Error using shapley (line 233)
Blackbox model must be a classification model, regression model, or function handle
Error in untitled (line 10)
explainer1 = shapley(net,P,’QueryPoint’,queryPoint); Hi there, I trained a BP nerual network using newff function, and want to obtain its Shapley values and swarmchart graph. But I have got the following error:
Code:
P = [2 3 1;3 4 5;1 3 4;4 6 7;2 7 3]’;
T = [1 2 3 4 5];
net=newff(P,T,5,{‘tansig’ ‘purelin’},’trainlm’);
[net,tr]=train(net,P,T);
queryPoint = P(:,1);
explainer1 = shapley(net,P,’QueryPoint’,queryPoint);
Error:
Error using shapley (line 233)
Blackbox model must be a classification model, regression model, or function handle
Error in untitled (line 10)
explainer1 = shapley(net,P,’QueryPoint’,queryPoint); shapley MATLAB Answers — New Questions
Can STUN/TURN traffic for AVD vnet be routed directly to internet and not AzureFirewall/NVA?
I got a simple AVD pool with 4 hosts located in regionA. All hosts are in single vnetA which is globally peered with vnetB in regionB where AzureFirewall is. Route table is assigned to vnetA to route AVD traffic to internet and 0.0.0.0/0 to private IP of AF in vnetB.
With the ShortPath being made available for Public networks I left it turned on and added following ranges to route directly to internet from vnetA:
20.202.0.0/1613.107.17.41/3213.107.64.0/1852.112.0.0/1452.120.0.0/14
RTT is anywhere from 80 to 180ms for all clients that are local to the vnetA region where hosts are, which seems high.
Turning off ShortPath resulted in unexpected “GraphicsCapsNotReceived” errors which is a separate issue.
I got a simple AVD pool with 4 hosts located in regionA. All hosts are in single vnetA which is globally peered with vnetB in regionB where AzureFirewall is. Route table is assigned to vnetA to route AVD traffic to internet and 0.0.0.0/0 to private IP of AF in vnetB. With the ShortPath being made available for Public networks I left it turned on and added following ranges to route directly to internet from vnetA:20.202.0.0/1613.107.17.41/3213.107.64.0/1852.112.0.0/1452.120.0.0/14RTT is anywhere from 80 to 180ms for all clients that are local to the vnetA region where hosts are, which seems high. Turning off ShortPath resulted in unexpected “GraphicsCapsNotReceived” errors which is a separate issue. Read More
Conditional Formatting, just to change the the color of the font
@anyone I know there has to be a simple solution to this, and I’ve done it before, but for some reason the document I’m working on will not accept it. Not sure what I’m doing wrong.
I just need the numbers to show up black if they’re positive, or red if they’re negative. Blank background/empty cell. Help please?
@anyone I know there has to be a simple solution to this, and I’ve done it before, but for some reason the document I’m working on will not accept it. Not sure what I’m doing wrong.I just need the numbers to show up black if they’re positive, or red if they’re negative. Blank background/empty cell. Help please? Read More
My journey to the cloud with Microsoft Intune
We sat down with IT pros who have made the journey to cloud-native endpoints with Microsoft Intune and asked them what worked well, what didn’t, and how their day-to-day is different now that they are managing endpoints in the cloud.
In the condensed interviews, we hope you’ll find something you can relate to and get motivated to take the next steps in your own cloud journey. We’ve indexed the interviews and provided transcripts so you can find what you’re looking for – and if you can’t, join the conversation in the comments:
IT pro perspectives teaser
Hear from several IT pros and their quick thoughts on the journey to cloud-native endpoint management with Microsoft Intune.
Watch the video >
Anders Ljungdahl, Solution Architect, and Jennie Strömvall, IT Technician
Learn about their strategy when it came to deploying Intune and how it benefited their day-to-day activites.
Watch the video >
James Robinson, End User Computing Workstream Lead
Hear about a consultant’s experiences of customers and observations on the process of migrating to Intune.
Watch the video >
Walker McAninch, Senior Endpoint Engineer
Learn about the experience of migrating more than 1,000 devices to the cloud from an on-premises environment.
Watch the video >
We sat down with IT pros who have made the journey to cloud-native endpoints with Microsoft Intune and asked them what worked well, what didn’t, and how their day-to-day is different now that they are managing endpoints in the cloud.
In the condensed interviews, we hope you’ll find something you can relate to and get motivated to take the next steps in your own cloud journey. We’ve indexed the interviews and provided transcripts so you can find what you’re looking for – and if you can’t, join the conversation in the comments:
IT pro perspectives teaser
Hear from several IT pros and their quick thoughts on the journey to cloud-native endpoint management with Microsoft Intune.Watch the video >
Anders Ljungdahl, Solution Architect, and Jennie Strömvall, IT Technician
Learn about their strategy when it came to deploying Intune and how it benefited their day-to-day activites.Watch the video >
James Robinson, End User Computing Workstream Lead
Hear about a consultant’s experiences of customers and observations on the process of migrating to Intune.Watch the video >
Walker McAninch, Senior Endpoint Engineer
Learn about the experience of migrating more than 1,000 devices to the cloud from an on-premises environment.Watch the video > Read More
Replacement for S4UClient.UpnLogon in Windows Identity Foundation
Good morning, I need a replacement for the S4UClient.UpnLogon to be used with Windows Identity Foundation. The goal was to impersonate the SPWeb.CurrentUser in order to make a REST API call using HttpClient. However, the error “The name provided is not a properly formed account name” is encountered.
I tried to create an instance of Windows Identity using only SPWeb.CurrentUser.Name, but this resulted in the error “A specified logon session does not exist. It may already have been terminated.”
Additionally, I tried to create an instance of Windows Identity with a static user (Example: “CONTOSOuser1”), but this also led to the error “A specified logon session does not exist. It may already have been terminated.”
Good morning, I need a replacement for the S4UClient.UpnLogon to be used with Windows Identity Foundation. The goal was to impersonate the SPWeb.CurrentUser in order to make a REST API call using HttpClient. However, the error “The name provided is not a properly formed account name” is encountered.I tried to create an instance of Windows Identity using only SPWeb.CurrentUser.Name, but this resulted in the error “A specified logon session does not exist. It may already have been terminated.”Additionally, I tried to create an instance of Windows Identity with a static user (Example: “CONTOSOuser1”), but this also led to the error “A specified logon session does not exist. It may already have been terminated.” Read More