Running matlab script from within bash script


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Running matlab script from within bash script
# 1  
Old 02-17-2011
Running matlab script from within bash script

Hi guys,

I'm new to scripting and I'm wondering if I can run a matlab script from within a bash script.

Basically, at the minute I have a bash script which creates a file "bottfile.xyz"

I then import "bottfile.xyz" into matlab using importdata('bottfile.xyz'). Then I just run the matlab script and away it goes.

So is there a way for me to just run my bashscript, and get it to run the matlab script also?

Thanks a lot,
J
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Running nmap via bash script

Hello fellow scripters... I am trying to set up a script for work that reads the contents of a file of IP address and network names, takes these and runs a given nmap scan against them and then saves the output to a file with the filename of the network name. Such as... IP file looks like... (4 Replies)
Discussion started by: hawkeyesc72
4 Replies

2. Shell Programming and Scripting

Bash shell script to check if script itself is running

hi guys we've had nagios spewing false alarm (for the umpteenth time) and finally the customer had enough so they're starting to question nagios. we had the check interval increased from 5 minutes to 2 minutes, but that's just temporary solution. I'm thinking of implementing a script on the... (8 Replies)
Discussion started by: hedkandi
8 Replies

3. Shell Programming and Scripting

script running by sh but not by bash

execute the attached script as, bash -x INFA_MAP_GEN_XML.sh "/export/home/e120945/INFORMATICA_MAPPING_GENERATOR/SOURCE" "INFA_TEMPLATE.csv" "/export/home/e120945/INFORMATICA_MAPPING_GENERATOR/TARGET" "UNIX" "/export/home/e120945/INFORMATICA_MAPPING_GENERATOR/SETUP"... (5 Replies)
Discussion started by: 120945
5 Replies

4. Shell Programming and Scripting

Output of matlab as a variable for shell script

I'm running a matlab code within a shell script. This is how I do it, matlab -nodesktop -nosplash -nojvm -r "my_program;quit" This works fine. My matlab code prints out a single number, say "ans = 10" for example. I want to assign this to a variable in the shell script. I tried doing this... (18 Replies)
Discussion started by: lost.identity
18 Replies

5. UNIX for Dummies Questions & Answers

Help Running a Check in Bash Script

Hey guys, so I wrote a small script that pretty much just takes in two numbers and counts from the first to the second, e.g. unknown-hacker|544> count.sh 1 3 1 2 3 My problem is I want to make it so that if you input invalid parameters, such as non-numerical characters, more than 2... (2 Replies)
Discussion started by: Duo11
2 Replies

6. UNIX for Dummies Questions & Answers

Running Executable in Bash Script

Hey guys, so I've been trying to write a bash script called runSorter.sh that runs an executable that also takes in some parameters and outputs the results to a text file. The executable, sorter, takes in a number parameter. I want to make it so that you can input as many number parameters into... (4 Replies)
Discussion started by: Duo11
4 Replies

7. Shell Programming and Scripting

Validate BASH script before running it...

Hello, Is there some way to validate a bash script before running it. I want to make sure all of the syntax and everything is good so that I dont get a false return code. Thanks, tom (7 Replies)
Discussion started by: tjones1105
7 Replies

8. Shell Programming and Scripting

Script running in bash 3.0 not in 3.2

I have wasted one working day writing this scripts. It compares two folders and make a good tabbed report about their differences. #!/bin/bash function DRAW_DEPTH () { ROUND=$1 while do printf %s " " ROUND=`expr $ROUND - 1` done printf %s "|- " } function MAIN () {... (9 Replies)
Discussion started by: trutoman
9 Replies

9. UNIX for Advanced & Expert Users

debugging an already running bash script

# ps -ef | grep rc root 13903 1 0 08:56 ? 00:00:00 /usr/sbin/automount --timeout=60 /archive file /etc/auto_archive root 10706 1 0 08:55 ? 00:00:00 /bin/bash /etc/rc.d/rc 3 root 2933 20071 0 19:38 pts/1 00:00:00 grep rc Is there any way to debug the... (1 Reply)
Discussion started by: marcpascual
1 Replies

10. Shell Programming and Scripting

Running a script from script (bash)

Hello I am a UNIX noob, attempting to use Cygwin on Windows XP to build a program. I am trying to get a few scripts together that can automate some tasks and I have run into a problem. Basically this is related to calling one script from another. I found this thread in my search but am too... (1 Reply)
Discussion started by: bobban
1 Replies
Login or Register to Ask a Question
LOADXSIL(1)						User Contributed Perl Documentation					       LOADXSIL(1)

NAME
loadxsil - load simulation data into matlab SYNOPSIS
loadxsil('<xsil_file>') DESCRIPTION
Utility script bundled with xmds, used to load simulation output data (from the xsil data file) into matlab, where the results can be pre- sented graphically. To load data from the xsil file data_file.xsil, enter at the matlab command prompt: >> loadxsil('data_file.xsil') EXAMPLES
At the matlab command prompt: >> loadxsil('nlse.xsil') loads the data contained in nlse.xsil into matlab AUTHORS
Written by Paul Cochrane BUGS
No known bugs. However, the loadxsil script does not work in Matlab version 4.0 or below; it can only be used with Matlab version 5.0 and above. Users with Matlab 4.0 can use the xsil2graphics utility as a means to import data into Matlab. SEE ALSO
xmds(1), xsil2graphics(1) http://www.xmds.org COPYRIGHT
Copyright (C) 2003-2004 Code contributed by Paul Cochrane This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MER- CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. perl v5.8.2 2004-03-11 LOADXSIL(1)