Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Simple script for separating files Post 302233840 by hertingm on Monday 8th of September 2008 03:46:37 PM
Old 09-08-2008
Thanks for your suggestions. I can assure you it isn't homework. I work in a fMRI lab and we use linux/unix based software for doing analysis and I just started and am trying to slowly learn how to write scripts to separate our dicom files to make my life easier.

Most of your suggestions are still foreign to me. So I will try to work on it, but it might take me a while to even get up to that point.

Thanks,

Megan
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Simple script uploading *.dem files to an ftp

Hello.. i want to create a simple script that's upload all the *.dem files from one directory to ftp and then delete them. Any help? (3 Replies)
Discussion started by: TuXaKoS
3 Replies

2. Shell Programming and Scripting

Merging files into a single tab delimited file with a space separating

I have a folder that contains say 50 files in a sequential order: cdf_1.txt cdf_2.txt cdf_3.txt cdf_3.txt . . . cdf_50.txt. I need to merge these files in the same order into a single tab delimited file. I used the following shell script: for x in {1..50}; do cat cdf_${x}.txt >>... (3 Replies)
Discussion started by: Lucky Ali
3 Replies

3. UNIX for Dummies Questions & Answers

any script for joining files based on simple conditions

Condition1; If NPID and IndID of both input1 and input2 are same take all the vaues relevant to them and print together as output Condition2; IDNo in output: Take the highly repeated same letter of similar NPID-IndID as *1* Second highly repeated same letter... (0 Replies)
Discussion started by: stateperl
0 Replies

4. Shell Programming and Scripting

Simple script to count files

Hello, I am new to shell scripting and I need your help. I have found similar scripts in the forum but I need further assistance. I am building a script to use hourly in cron to mailx me if the number of files in a path is less than e.g 100 I have started with the following: #!/bin/sh... (2 Replies)
Discussion started by: drbiloukos
2 Replies

5. Shell Programming and Scripting

Simple script to find common strings in two files

Hi , I want to write a simple script. I have two files file1: BCSpeciality Backend CB CBAPQualDisp CBCimsVFTRCK CBDSNQualDisp CBDefault CBDisney CBFaxMCGen CBMCGeneral CBMCQualDisp file2: CSpeciality Backend (8 Replies)
Discussion started by: ramky79
8 Replies

6. Shell Programming and Scripting

Separating Pattern Into Separate Files

I am trying to separate a specific pattern match into separate files. Sometimes there is only one pattern match, but other times there could be multiple (up to 6 or 8). Pattern is as follows - its starts with NYZ or VTZ and ends with $$. Again looking to get those blocks of data from one big... (17 Replies)
Discussion started by: Double-E
17 Replies

7. UNIX for Dummies Questions & Answers

Simple version control script for text files

HI guys, Could you help me writing a simple version control script for a text files. the format could be ./version_control <file(s)> (I want it to be able to work with more than 1 file at the same time) commands are add and get, add means you add new file(s) to the archive, get means you... (4 Replies)
Discussion started by: s3270226
4 Replies

8. Shell Programming and Scripting

Separating list of input files (*.file) with a comma in bash script

Hi all, I'm trying to get a bash script working for a program (bowtie) which takes a list of input files (*.fastq) and assembles them to an output file (outfile.sam). All the .fastq files are in one folder in my home directory (~/infiles). The problem is that the 'bowtie' requires that... (7 Replies)
Discussion started by: TuAd
7 Replies

9. Programming

Separating two classes in two files

I have a file Map.hh shown below. I want to put the two classes Phase and Map in two different files Phase.hh and Map.hh. I have forward declaration before the Map class. How can I tackle this situation? ////////////////////////////////////////////////////////////////////////// #ifndef... (3 Replies)
Discussion started by: kristinu
3 Replies

10. Shell Programming and Scripting

How to generate a csv files by separating the values from the input file based on position?

Hi All, I need help for doing the following. I have a input file like: aaaaaaaaaabbbbbbbbbbbbbbbbbbbb cccbbbbbaaaaaadddddaaaabbbbbbb now I am trying to generate a output csv file where i will have for e.g. 0-3 chars of each line as the first column in the csv, 4-10 chars of the line as... (3 Replies)
Discussion started by: babom
3 Replies
STDA(1) 							   User Commands							   STDA(1)

NAME
stda - Simple Tools for Data Analysis (STDA) DESCRIPTION
STDA includes some primary tools for data analysis. You can evaluate sums, averages, integrals, derivatives, histograms or probability dis- tribution functions of 1-d data, and eventually plot the results. The programs are stand-alone tools (supporting the standard UNIX input and output pipelines) intended for data processing from the command line. It should be noted that all but one of the scripts use awk and core system utilities. For plotting you have to install Gnuplot (see http://gnuplot.info) since 'muplot' is a wrapper around it. In sum- mary, the package provides utilities for straightforward analysis of data series where a complex analytical approach is not needed and where an ultimate numerical precision with floating-point numbers is not critical. Some general examples of application cases include eval- uating usage statistics from server logfiles, determining a response time distribution from a series of queries to a [remote] service, pro- ducing a plot from multiple data files, etc. This software should be considered as an open project to be extended with new command-line driven utilities helpful for performing common data analysis tasks. Any contributions and suggestions are welcome. Following programs are included in the distribution: * maphimbu - histogram builder for 1-d numerical and text data * mintegrate - average/sum/integral/derivative of 1-d numerical data * mmval - find minimum and maximum value in a data set * muplot - plot a multi-curve figure from multiple data by using Gnuplot * nnum - produce a series of equally separated integers or floats * prefield - prepare input file for 'muplot' to plot 2-d fields by arrows EXAMPLES
- Evaluate the current apache2 logfile and make an unique list of the hostnames (respectively ip-addresses) sorted by the total number of their http requests: maphimbu -rs2 /var/log/apache2/access.log - On a X terminal plot the probability function and the cumulative distribution function of a sin(x) data sample: nnum -3.14159 3.14159 0.00001 %.6g |awk '{ print $1, sin($1) }' | maphimbu -d0.01 -x2 -ns1 |mintegrate -d0.01 -x1 -y3 -S |muplot lp - 1:3,4 COPYRIGHT
Copyright (C) 2009, 2011-2012 Dimitar Ivanov <dimitar.ivanov@mirendom.net> License: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. stda 1.1.1 February 2012 STDA(1)
All times are GMT -4. The time now is 01:09 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy