Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
setopt.m
Package: Wavelet_denoising.rar [view]
Upload User: speoil
Upload Date: 2022-06-23
Package Size: 224k
Code Size: 3k
Category:
Wavelet
Development Platform:
Matlab
- function option = setopt(opt_par,default);
- % option = setopt(opt_par,default);
- %
- % SETOPT can modify a default option vector with user specified options.
- %
- % Input:
- % opt_par : Users desired option vector
- % default : Program default option vector
- %
- % Output:
- % option : New option vector
- %
- % Example:
- % opt_par = [1 2 3 4];
- % default = [1 1 1 1];
- % option = setopt(opt_par,default)
- % option = 1 2 3 4
- %
- %File Name: setopt.m
- %Last Modification Date: 10/26/95 13:06:18
- %Current Version: setopt.m 2.4
- %File Creation Date: Thu Nov 11 10:40:22 1993
- %Author: Jan Erik Odegard <odegard@ece.rice.edu>
- %
- %Copyright (c) 2000 RICE UNIVERSITY. All rights reserved.
- %Created by Jan Erik Odegard, Department of ECE, Rice University.
- %
- %This software is distributed and licensed to you on a non-exclusive
- %basis, free-of-charge. Redistribution and use in source and binary forms,
- %with or without modification, are permitted provided that the following
- %conditions are met:
- %
- %1. Redistribution of source code must retain the above copyright notice,
- % this list of conditions and the following disclaimer.
- %2. Redistribution in binary form must reproduce the above copyright notice,
- % this list of conditions and the following disclaimer in the
- % documentation and/or other materials provided with the distribution.
- %3. All advertising materials mentioning features or use of this software
- % must display the following acknowledgment: This product includes
- % software developed by Rice University, Houston, Texas and its contributors.
- %4. Neither the name of the University nor the names of its contributors
- % may be used to endorse or promote products derived from this software
- % without specific prior written permission.
- %
- %THIS SOFTWARE IS PROVIDED BY WILLIAM MARSH RICE UNIVERSITY, HOUSTON, TEXAS,
- %AND CONTRIBUTORS AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,
- %BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- %FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RICE UNIVERSITY
- %OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- %EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- %PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- %OR BUSINESS INTERRUPTIONS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- %WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- %OTHERWISE), PRODUCT LIABILITY, OR OTHERWISE ARISING IN ANY WAY OUT OF THE
- %USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- %
- %For information on commercial licenses, contact Rice University's Office of
- %Technology Transfer at techtran@rice.edu or (713) 348-6173
- %
- %Change History:
- %
- if (nargin < 2)
- error('You need two inputs');
- end;
- len = length(opt_par);
- option = zeros(size(default));
- option(1:len) = opt_par(1:len);
- option = option + (option == 0).*default;