The option wasn't available in R2009b, but it is present in R2015b. My release notes go from to R2012b to present, and it's not mentioned in there. I know the 'legacy' option was introduced in R2012b, but there's no mention of 'stable'. I have to conclude it was sometime in after R2009b and before R2012b.
Any recollections?

7 件のコメント

dpb
dpb 2025 年 8 月 10 日
Mathworks' penchant for removing access to older versions documentation is infuriating, indeed...
Rik
Rik 2025 年 8 月 10 日
When I saw the question, I thought it was R2012a, but I'm away from my pc where I have Too Many Versions installed.
There was a CAB meeting where I mentioned being a weirdo supporting 6.5 in my code. Someone responded within a minute with a graph created in 6.5. That person might know. Was it @Steven Lord perhaps? I can't find it in my history.
Steven Lord
Steven Lord 2025 年 8 月 10 日
I don't remember off the top of my head, but I can check Monday morning.
DGM
DGM 2025 年 8 月 10 日
I knew @Rik would probably have the goods :)
Now I have to decide if I actually want to bother implementing the functionality in older versions.
Rik
Rik 2025 年 8 月 10 日
編集済み: Rik 2025 年 8 月 10 日
Apparently that was a good guess (both mine and yours) XD
You can easily circumvent it by sorting the list yourself (storing the indices), using unique (with the index output) and using the index(index)-trick to grab the elements from the original array.
If I recall correctly I had cause to do something like this and that was my approach. This may require some additional thought/testing to implement on arrays, but the vector case isn't that tricky to implement.
disp('edit: I''m not as smart as I thought'),disp('(or at least not the first with this idea)')
edit: I'm not as smart as I thought (or at least not the first with this idea)
I started writing something nice from scratch, and then I realized Sean had already written the code you need more than 13 years ago.
DGM
DGM 2025 年 8 月 10 日
Yeah, I saw that, but I also need to re-sort the IC index list to match. I just haven't had enough contiguous moments of attention to actually think about it.
DGM
DGM 2025 年 8 月 10 日
I swear it's like I forgot that ismember() exists.
% some inputs
V0 = rand(15,3);
V0 = V0(randi([1 10],10,1),:); % points
F0 = [1 2 3; 4 5 6; 7 8 9]; % row subscripts in V0
% this is what i need to replicate
[V1,~,ic0] = unique(V0,'rows','stable');
F1 = ic0(F0);
% this is it replicated without 'stable'
[~,ia,ic] = unique(V0,'rows');
[ias sortmap] = sort(ia);
[~,ics] = ismember(ic,sortmap);
V2 = V0(ias,:);
F2 = ics(F0);
% they match
isequal(V1,V2)
ans = logical
1
isequal(F1,F2)
ans = logical
1

サインインしてコメントする。

 採用された回答

Stephen23
Stephen23 2025 年 8 月 10 日
編集済み: Walter Roberson 2025 年 8 月 11 日

0 投票

1 件のコメント

DGM
DGM 2025 年 8 月 10 日
Your search-fu is stronger than mine. Thank you.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Introduction to Installation and Licensing についてさらに検索

製品

質問済み:

DGM
2025 年 8 月 10 日

編集済み:

2025 年 8 月 11 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by