You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
Link(target) creates a Link object pointing to location or code defined by target, e.g., a URL.
Link(target, text) will display text instead of the target.
To add a hyperlink to a longer string, e.g., using sprintf, use the Link object's str property.
Examples included in help:
Example
Link('matlab:docsearch hyperlinks', 'Learn more about MATLAB hyperlinks')
Example
lnk = Link('matlab:ezplot(@cos)', 'Display cosine function')
Example
lnk = Link('http://mathworks.com/matlabcentral/', 'MATLAB Central');
disp('The link can be shown by normal display:')
lnk
disp('Or by using the function disp:')
disp(lnk);
disp('Alternatively, access the object''s str property:')
fprintf('Go to %s for lots of great resources.\n', lnk.str);
Cite As
Sky Sartorius (2026). Link (https://se.mathworks.com/matlabcentral/fileexchange/48638-link), MATLAB Central File Exchange. Retrieved .
General Information
- Version 1.1.0.2 (1.88 KB)
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux
