Syntax
amazon([searchterms])
Input Parameter
searchterms : | | string for search |
Examples
amazon
amazon Motor N20
Copyright 2022-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth
Algorithm (Workflow)
This MATLAB function, named amazon
, is designed to open the Amazon website with a specific search query directly from MATLAB. It is part of a series of auxiliary procedures created to streamline web access without the interference of advertisements.
Input Parameters
- searchterms: A string representing the search query to be used on Amazon's website.
Algorithm Steps
- The function begins by converting the input arguments (
varargin
) into a single string using the helper function cell2str
.
- It checks if the resulting string
s
is empty:
- If
s
is empty, it sets the URL to Amazon's homepage: 'http://www.amazon.de/'
.
- If
s
is not empty, it constructs a search URL by concatenating the base URL 'http://www.amazon.de/search/s?k='
with the search terms.
- The constructed URL is then opened in the default web browser using the
web
function.
- If there is an output argument requested, the function assigns the search terms to
varargout{1}
.
Example Usage
amazon
: Opens the Amazon homepage.
amazon('Motor N20')
: Opens Amazon with a search for "Motor N20".
Algorithm explaination created using ChatGPT on 2025-08-19 07:50. (Please note: No guarantee for the correctness of this explanation)
Last html export of this page out of FM database by TL: 2025-09-21