plt savefig('some_plot png'plt savefig('some_plot pdf'plt savefig('some_plot jpg'plt savefig('some_plot eps'png format pdf format jpg format encanspulated postscript format for the reader who is into linear algebrait may be useful to know that standard matrix/vector operations are straightforward with arrayse matrix-vector multiplication what is needed thoughis to create the right variable types (after having imported an appropriate modulefor exampleassume you would like to calculate the vector (note that boldface is used for vectors and matricesas axwhere is matrix and is vector we may do this as illustrated by the program matrix_vector_product py reading from numpy import zerosmattranspose zeros( mat(xx transpose(xx[ [ pick some values zeros(( , ) mat(aa[ , [ , [ , [ , the following gives since ithe identity matrix * print herex is first created as an arrayjust as we did above then the variable type of is changed to mati matrixby the line mat(xthis is followed by transpose of from dimension (the default dimensionto with the statement transpose( )before some test values are plugged in the matrix is first created as two dimensional array with zeros(( , )before conversion and filling in values take place finallythe multiplication is performed as * note the number of parentheses when creating the two dimensional array running the program gives the following output on the screen[[ [ ]error messages and warnings all programmers experience error messagesand usually to large extent during the early learning process sometimes error messages are understandablesometimes they are not anywayit is important to get used to them one idea is to start with program that initially is workingand then deliberately introduce errors in itone by one (but remember to take copy of the original working code!for each error