Archive for the ‘Scripting’ Category

Counting the Unique Elements in a MATLAB Array

Saturday, November 12th, 2011

I was looking for a way to count the number of unique values of an array as part of an assignment. Google turned up with some ideas, but no definite answers. Then I came to know of two functions unique and histc. Here is the code to count the unique elements

Read the full content

Packing and Unpacking in Perl

Friday, June 19th, 2009

This post is more to serve as a reminder to myself. Perl has a handy keyword called pack which helps to store a variable in the template specified. pack thus takes two arguments. The first argument is the template and the second argument is the string to be packed according to the template.

Read the full content

Bash YouTube Downloader

Sunday, June 7th, 2009

Here is a simple bash script to download YouTube Videos in mp4 via command line.

Read the full content

IP from Command Line

Friday, June 5th, 2009

This is a quick post. I was wondering how to get my IP Address without going to popular sites. I came up with this bash script

Read the full content