Skip to content

Instantly share code, notes, and snippets.

@alexpreynolds
Created March 22, 2016 17:59
Show Gist options
  • Save alexpreynolds/e3cb2bf3901f618e2f8e to your computer and use it in GitHub Desktop.
Save alexpreynolds/e3cb2bf3901f618e2f8e to your computer and use it in GitHub Desktop.
Generate 10k-row, 1k-column matrix of random integers between 1 and 100
#!/usr/bin/env python
from random import randint
for r in xrange(0, 10000):
print '\t'.join([str(x) for x in [randint(0, 100) for p in range(0, 1000)]])
@alexpreynolds
Copy link
Author

$ ./random-mtx.py > random.mtx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment