Integrate_Python_code_with_Simulink icon indicating copy to clipboard operation
Integrate_Python_code_with_Simulink copied to clipboard

Add Open in MATLAB Online badge

Open yanndebray opened this issue 1 year ago • 1 comments

Open in MATLAB Online

Can be created from this page; https://www.mathworks.com/products/matlab-online/git.html

yanndebray avatar Apr 15 '24 19:04 yanndebray

Would require to add a setup file like this

% % setup.m

% create pip folder if it doesn't exist
if ~exist('pip', 'dir')
    mkdir('pip');
    
    % retrieve pip files
    files = ["getwheel","setuppip","pipinstall","piplist","pipcmd","pipshow","pipuninstall"];
    BASE_URL = "https://raw.githubusercontent.com/yanndebray/matlab-with-python-book/main/code/";
    for i = 1:length(files)
    url = BASE_URL+files{i}+".m";
    websave("pip/"+files{i}+".m",url);
    end
end

addpath("pip/")

% install opencv package
pipinstall("opencv-python")

yanndebray avatar Apr 15 '24 19:04 yanndebray