
Akira Agata
MathWorks
Statistics
RANK
55
of 275.961
REPUTAZIONE
3.050
CONTRIBUTI
0 Domande
807 Risposte
ACCETTAZIONE DELLE RISPOSTE
0.00%
VOTI RICEVUTI
592
RANK
3.744 of 18.584
REPUTAZIONE
370
VALUTAZIONE MEDIA
5.00
CONTRIBUTI
3 File
DOWNLOAD
32
ALL TIME DOWNLOAD
2553
CONTRIBUTI
0 Post
CONTRIBUTI
2 Pubblico Canali
VALUTAZIONE MEDIA
30
CONTRIBUTI
0 Punti principali
NUMERO MEDIO DI LIKE
Content Feed
Finding indices of certain numbers from simulation data
How about using ismembertol function? The following is an example: x = [1, 1/3, 3/4, 4/5, 1, 1.1]; idx = ismembertol(x, 0.33,...
22 giorni fa | 0
画像の明るさ変更
最近追加された関数を使用しないということでしたら、MATLABによるコントラスト強調方法 のページが参考になるかと思います。
circa un mese fa | 0
| accettato
rename files in a folder
How about the following solution? % Create list of all files in the current folder s = dir(pwd); s = struct2table(s); % Ex...
circa un mese fa | 1
| accettato
Help on creating a new column and fill values at specific locations
How about the following? % Example v1 = 1:4; v2 = [3, 6, 8, 10]; v3 = 1:10; % Create the new vector newVec = zeros(size(...
circa un mese fa | 0
| accettato
how to remove the cracks on image?
How about using inpaintCoherent or inpaintExemplar function?
circa un mese fa | 0
Marker on contourf plot
Please use (x,y) coordinate for plotting markers. The following is an example: load('Test.mat'); % Find (x,y) coordinate of...
3 mesi fa | 1
Create logarithmically spaced vector with points spaced more closely at far end of vector
Like this? % Normal log-spaced vector x1 = logspace(1, 2, 10); % Create inverse log space delta = diff(x1); delta = flipl...
4 mesi fa | 1
| accettato
How can I change the Nan values in a matrix by the values in cells array?
If you want to replace NaN by the given value in linear index order, the following will be one possible solution: % Given matri...
5 mesi fa | 1
画像から1ピクセルの長さを求めたい
コメントありがとうございます。 方眼幅のピクセル数を自動的に算出したいとのことですが、以下の方法はいかがでしょうか? ちなみに、今回のケースは方眼が白色の線ですので平均輝度値のピークを検出していますが、黒線の場合には平均輝度値に -1 を乗算してピーク...
5 mesi fa | 2
| accettato
バイナリ画像における水平方向の白領域の広がりを測定したいです。
regionprops で重心を計算する際に、あわせて Bounding Box を計算しておいて、そのボックスの幅を「体領域における水平方向の幅」と見なせないでしょうか? % 重心の描写 % s = regionprops(binary1,'cent...
5 mesi fa | 2
| accettato
headerが複数階層のcsvファイルを構造的に読み込む方法
readcell でまずファイル全体を読み込んだ後、変数名に関する部分と数値データの部分を分けて、最後にテーブル型変数として纏めるという方法はいかがでしょうか?以下はその一例です。 % readcell でとりあえず全体を読み込む C = readce...
5 mesi fa | 1
| accettato
How to obtain the outermost elements of a 2D matrix ?
How about the following? % Sample matrix M = magic(5); % Replace non-outermost element as NaN M(2:end-1, 2:end-1) = nan; ...
6 mesi fa | 2
| accettato
Rawデータをjpgに変換したいです
関連する関数 raw2rgb, imresize, imwrite を順に適用することで実現可能かと思います。
6 mesi fa | 1
| accettato
画像をパディングし正方形にする方法
関数 padarray を使って、以下のようにする方法はいかがでしょうか? % サンプル画像 (1000×200ピクセル) I_in = randi(255, [1000 200], "uint8"); % 縦横のピクセル数とその差を取得 sz...
6 mesi fa | 1
| accettato
エラーバーを任意の点だけ表示する方法はありませんか
plot と errorbar を同じ色で重ねて表示する方法はいかがでしょうか? たとえば 25個の (x,y) データがあり、5, 10, 15, 20番目のデータのみにエラーバーを表示したいとすると、以下のようになります。 % データ x = 1...
6 mesi fa | 0
| accettato
saving 3 dimensional data in excel file in a particular format
How about the following? for kk = 1:5 writematrix(squeeze(A(kk,:,:)), "yourExcel.xlsx", "Sheet", kk); end
6 mesi fa | 1
| accettato
x, yの実験データに対し、x,yを両辺に複数もつ複雑な理論式(x,yを変数とし、未知の係数を含む関数)によってフィッティングする方法を教えてください。
いくつかやり方がありますが、たとえば (x, y) の全データに対する左辺と右辺の差の二乗和を「 (a, b) を入力変数とする関数」として定義して、fminsearch で (a, b) の最適値を求めるというのはいかがでしょうか?
6 mesi fa | 0
Using load for different files with varying names
How about the following? for kk = 1:25 fileName = sprintf('data%d.mat', kk); load(fileName) % % Some proce...
7 mesi fa | 1
| accettato
円を配列で表す
いろいろなやり方があると思いますが、たとえばMATLABの基本関数のみを使う以下の方法はいかがでしょうか? % 初期配列 J = repmat(6.5, 710, 710); % 中心 (335, 335), 半径 135 の円内のグリッド点を示...
7 mesi fa | 3
| accettato
Find value based on adjacent value condition and insert into new variable
ismember function will be helpful for this task, like: % Sample matrix A = [(0:50)', rand(51,1)]; % Second matrix with inde...
7 mesi fa | 1
| accettato
Rename a lot of files
How about the following? fileList = dir('*.csv'); for kk = 1:numel(fileList) fileNum = extractBetween(fileList(kk).name,'...
7 mesi fa | 1
Trying to plot a temperature distribution and generate a temperature contourn!
How about the following? L = 1; W = 1; [xGrid, yGrid] = meshgrid(0:0.025:1, 0:0.025:1); T = zeros(size(xGrid)); for n =...
7 mesi fa | 2
| accettato
How to find the midpoint between two curves in an image
How abou the following? % Load image I = imread('https://jp.mathworks.com/matlabcentral/answers/uploaded_files/1079075/curve.P...
8 mesi fa | 1
| accettato
I need to repeat numbers in an array with a certain number of repetitions for each value without(repelem or repmat)
I'm not sure why you do not prefer repelem/repmat... Anyway, how about the following solution? % Example list_1 = [2;3;5;6]; ...
8 mesi fa | 2
| accettato
Trouble using split function in matlab
How about the following? % Example dates = {'3/11/9102'; '3/12/9102'; '3/13/9102'; '3/14/9102'; '3/15/9102'}; % Split by '/...
8 mesi fa | 2
| accettato
Find the missing rows and newly added rows in two different excels sheets
How about the following? % Load the Excel files tNew = readtable('https://jp.mathworks.com/matlabcentral/answers/uploaded_file...
8 mesi fa | 2
| accettato
MPR-CTを読み込んで3Dとし、一部を球近似することはできますか?
MPR-CT画像から既に 3D モデルは作成済みだと想定します。 3D モデルが 3次元のバイナリイメージの形で利用可能だとすると、regionprops3 関数を使ってそれぞれの重心座標を算出できます。また、この関数でボリュームサイズも取得できますので...
9 mesi fa | 0
Average of every 25 rows in a table
Another possible solution: % Sample data data = rand(1000, 10); % Grouping group = repelem(1:size(data, 1)/25, 25)'; % ...
9 mesi fa | 1
ベクトルと平面のなす角の算出
順を追って説明します。 まず、ベクトル a と b のなす角は以下の式で求められます。 では平面とベクトル a のなす角は??というご質問ですが、考えてみると平面の法線ベクトルを使って求められそうです。 たとえば平面の法線ベクトルを n とすると...
11 mesi fa | 2
Storing values in a matrix out of nested for loops
how about the following? m1 = [0.5; 0.5]; m2 = [0.6; 0.4]; m3 = [0.2; 0.8]; [q, p, r] = meshgrid(m2, m1, m3); s4 = p.*q.*r;...
11 mesi fa | 1
| accettato