[Tutor] how to read data

lina lina.lastname at gmail.com
Sat May 7 11:17:36 CEST 2011


Hi,

As you will see I am a new beginner of learning python,

I met a problem, hope someone can guide me one or two and help me learn.

Here is the issue.


"e  c #3B3B3B " /* "1.15" */,
"f  c #343434 " /* "1.19" */,
"g  c #2E2E2E " /* "1.23" */,
"h  c #272727 " /* "1.27" */,
"i  c #212121 " /* "1.31" */,
"j  c #1A1A1A " /* "1.35" */,
"k  c #141414 " /* "1.38" */,
"l  c #0D0D0D " /* "1.42" */,
"m  c #070707 " /* "1.46" */,
"n  c #000000 " /* "1.5" */,

from below we can see the e = 1.15 .... n = 1.5..

"nnnnnnnnnneZVKWcbglnnnnnnnnADKSYjknnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnnnnnnlcdZTQSLGJMMDAnnnnncngbGKMHPTFJSWSZfhcejnnneSZdiilnnggnnkgnnnnnnjnnn",
"nnnnnnnnnnnmmjeaVRPLHGMJDADnnnnnlnnnUadTcfPNaeVbjkdcglnnnhnnnnnnnnnnnnlnnnnnnmnnn",
"nnnnnnnnnimfhfZURQLEJJKDADMnnnnnnnnncglcmnTXknYknniginnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnndiggfYTSOIHKGDADJMnnnnnjnmlZaicljPWiiShnjedfjnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnnkmhebQSQJFLKDADKMJnnnnhXiZYRMYYeYFVecPdjeaeijnnhfZnnnnnnnnnnnnnnnnnnnnnn",

and for above I want those a-Z get back to their numerical value, so I
can use this matrix and read by matlab.

Thanks ahead for any advice about how to achieve it.

I have attached the whole file. try.xpm at the end and as attachment.

Best regards,

lina


/* XPM */
/* Generated on May 5th */
/* This is the file*/
/* title:   "None" */
/* legend:  "Distance (nm)" */
/* x-label: "Residue Index" */
/* y-label: "Residue Index" */
/* type:    "Continuous" */
static char *gromacs_xpm[] = {
"81 81   40 1",
"A  c #FFFFFF " /* "0" */,
"B  c #F8F8F8 " /* "0.0385" */,
"C  c #F2F2F2 " /* "0.0769" */,
"D  c #EBEBEB " /* "0.115" */,
"E  c #E5E5E5 " /* "0.154" */,
"F  c #DEDEDE " /* "0.192" */,
"G  c #D8D8D8 " /* "0.231" */,
"H  c #D1D1D1 " /* "0.269" */,
"I  c #CBCBCB " /* "0.308" */,
"J  c #C4C4C4 " /* "0.346" */,
"K  c #BEBEBE " /* "0.385" */,
"L  c #B7B7B7 " /* "0.423" */,
"M  c #B1B1B1 " /* "0.462" */,
"N  c #AAAAAA " /* "0.5" */,
"O  c #A3A3A3 " /* "0.538" */,
"P  c #9D9D9D " /* "0.577" */,
"Q  c #969696 " /* "0.615" */,
"R  c #909090 " /* "0.654" */,
"S  c #898989 " /* "0.692" */,
"T  c #838383 " /* "0.731" */,
"U  c #7C7C7C " /* "0.769" */,
"V  c #767676 " /* "0.808" */,
"W  c #6F6F6F " /* "0.846" */,
"X  c #696969 " /* "0.885" */,
"Y  c #626262 " /* "0.923" */,
"Z  c #5C5C5C " /* "0.962" */,
"a  c #555555 " /* "1" */,
"b  c #4E4E4E " /* "1.04" */,
"c  c #484848 " /* "1.08" */,
"d  c #414141 " /* "1.12" */,
"e  c #3B3B3B " /* "1.15" */,
"f  c #343434 " /* "1.19" */,
"g  c #2E2E2E " /* "1.23" */,
"h  c #272727 " /* "1.27" */,
"i  c #212121 " /* "1.31" */,
"j  c #1A1A1A " /* "1.35" */,
"k  c #141414 " /* "1.38" */,
"l  c #0D0D0D " /* "1.42" */,
"m  c #070707 " /* "1.46" */,
"n  c #000000 " /* "1.5" */,
/* x-axis:  1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
69 70 71 72 73 74 75 76 77 78 79 80 */
/* x-axis:  81 */
/* y-axis:  1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
69 70 71 72 73 74 75 76 77 78 79 80 */
/* y-axis:  81 */
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnigebUSQNFHLOVUnnnnnnnnnnhfilgPdhWXMMNPGDA",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnkkfZWWQJJLKFJJnnnnnnnnnnnjknkXcgXUOTTNDAD",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnjcebVPSQHHMQOQUnnnnnnnnmkeabeaPVYPPLOLDADG",
"nnnnnnnnnnnnnnnnnnnnnnnnnmjnnnnnnnnnnnicWaXQKQRJLSVUUannnnnnnkebWTSTQIKOHKGKDADNP",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnmjbcdZQSWRKSYadjnnnnnnnfeZSUUUNGPRGLJDADLTN",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnmnnjadeXPZeeeinnnnnnnnnibeccVQTRGFDADKOTM",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnlnmfZdcSSXbYWbnnnnnnnnnmhhdcZRRSJDADJGLOM",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnmnnhaihXZfhcSZnnnnnnnnngdfZWSNMHDADFLKPUX",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnngkmgVagXXdigeknnnnnnngcTRXQMGFHDADJGGHPXW",
"nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnlehmfUbkbdknmknnnnnnnniZSTVMGHIDADHSRROYgh",
"nnnnnnnnnnnnnnnnnnnnnnnnnlgnnnnnnnnnnmdXRWaTLTZSVdfd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VaZaQKPWU",
"nnnnnnnnnnnnnnnnniefbVVWXNJnnnnnnnlfUQLFJKDADIIGNRRSWennlbZdgdeheUXchUTfghfjZQVZb",
"nnnnnnnnnnnnlhUaZQPURGFPTPFnnnnjXkZVKKFIIDADIIFMRSUYejnndXRWYXafeUXeiWammnmndXbfe",
"nnnnnnnnnnnnnnknnmlnnZYjnfTnnnnnaeVPMKHKDADKKILSUWaglnneUPGMPQTYYNRXcUWhknnncaekg",
"nnnnnnnnnnnnnnnnnnnnlYelmcPnnnnnmnleRQIDADIJFINRUZceinnldRNINGKPTJJRXTRegmlmbWcki",
"nnnnnnnnnnnnnnhniadgYLYccTHnnnnnenfZHKDADKIFKORVaefhlnnjZKRTZYafgWVcibXlnnnnjcjnn",
"nnnnnnnnnnnnnnhnnhiniSYildMnnnnmYgWPHDADIHFLPRUaehknnnjaQKILSSXdgVWfkednnnnnminnn",
"nnnnnnnnnnnnnlXhiaVddMMagaKnnnlcPZOJDADKQKKQXVWegdgnnnibQPKTZchnncgnnjmnnnnnnnnnn",
"nnnnnnnnnnnnnfTfbTWbWERZcUGnnkfXKTKDADHHRMKUcfeknnnnnnXQGGHPXbjnnghnnnnnnnnnnnnnn",
"nnnnnnnnnnnnnnZnnfdmmVYlnnbnnmfVKJDADJPZePVfkgjnnnnnnnXSJPHVbgnnnmnnnnnnnnnnnnnnn",
"nnnnnnnnnnnnjiWkmdalnXZmnngnneZOIDADKOWflVZlnilnnnnnnnZXPVGbgnnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnnnnngdXineennginnnnkiVTJDADJTZgnneknnnnnnnnnnnXXOZMgknnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnnnnngbPdeTXfgSXjnlcjdVMDADIKKPYemaXnnnnnnnnnnnRSNTSdlnnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnnnnnbSSdgXcknehnnnnYUKDADJOVXcmnnnjnnnnnnnnnnnWZXfcnnnnnnnnnnnnnnnnnnnnnn",
"nnnnnnnnnn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QHDADMVbWhnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"TKDADGPUVYilnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"LDADHQbinmnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"DADKQYjnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn",
"ADLTVgnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: try.xpm
Type: image/x-xpixmap
Size: 8878 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/tutor/attachments/20110507/52b3d345/attachment-0001.xpm>


More information about the Tutor mailing list