Thursday, September 15, 2016

Installing Latest PyMOL Software for FREE

BIOGEM

Introduction to PyMOL

PyMOL is a Python-enhanced OpenGL based molecular visualization tool. It excels at 3D visualization of proteins, small molecules, density, surfaces, and trajectories. It also includes molecular editing, ray tracing, and movies. Open Source PyMOL is available at SourceForge.net (https://sourceforge.net/projects/pymol/) for free to everyone. The commercial graphical end PyMOL is developed, maintained and distributed by Schrödinger, Inc (https://www.pymol.org/). PyMOL can produce high-quality 3D images of small molecules and biological macromolecules, such as proteins. According to the original author, almost a quarter of all published images of 3D protein structures in the scientific literature were made using PyMOL.

Requirements for PyMOL Installation

In this tutorial, I have explained how to install the latest PyMOL software (the latest version of PyMOL software as on September 15, 2016 is 1.8.3.2) for free. I have chosed Windows 10 Enterprise OEM 64-bit operating system to install the PyMOL software. So, I have downloaded all stable version executables in 64-bit. Before begining to install the PyMOL, we have to download the Python software and needed Python packages with same version. For example, I have chosen Python version 3.x, So I have downloaded the Python packages supporting 3.x version and x64(64-bit).

1. Python v3.5.2 - https://www.python.org/ftp/python/3.5.2/python-3.5.2-amd64.exe (File Size: 28.7 MB)

Download PyMOL and neccessary packages from the unofficial windows binaries portal (http://www.lfd.uci.edu/~gohlke/pythonlibs/)

2. PIP v8.1.2 - http://www.lfd.uci.edu/~gohlke/pythonlibs/dp2ng7en/pip-8.1.2-py2.py3-none-any.whl (File Size: 1.14 MB)

3. Numpy+MKL v1.11.1 - http://www.lfd.uci.edu/~gohlke/pythonlibs/dp2ng7en/numpy-1.11.1+mkl-cp35-cp35m-win_amd64.whl (File Size: 111 MB)

4. PMW v2.0.1 - http://www.lfd.uci.edu/~gohlke/pythonlibs/dp2ng7en/Pmw-2.0.1-py3-none-any.whl (File Size: 533 KB)

5. PyMOL v1.8.3.2 - http://www.lfd.uci.edu/~gohlke/pythonlibs/dp2ng7en/pymol-1.8.3.2-cp35-cp35m-win_amd64.whl (File Size: 7.03 MB)

6. PyMOL Launcher v1.0 - http://www.lfd.uci.edu/~gohlke/pythonlibs/dp2ng7en/pymol_launcher-1.0-cp35-cp35m-win_amd64.whl (File Size: 207 KB)

Total download size of the complete softwares will be around 148.61 MB.

Installation Procedure

1. Install the downloaded Python v3.5.2 sofware with administrator priviliges. Follow the Customize installation procedure as shown in the images below to change the installation directory.
BIOGEM
BIOGEM
BIOGEM
BIOGEM

2. Copy the downloaded Python packages PIP v8.1.2, PMW v2.0.1, PyMOL v1.8.3.2, PyMOL v1.0, PyMOL Launcher v1.0, and Numpy+MKL v1.11.1 to the directory (C:\Python35\Scripts).
BIOGEM

3. Run Command Prompt with administrator priviliges. Enter the command line (cd "C:\Python35\Scripts") to enter into Scripts directory.

4. Enter the following commands in the Commmand Prompt in the order given below to install PyMOL. Refer the snapshot given below for clarification.
  • pip install pip-8.1.2-py2.py3-none-any.whl
  • pip install numpy-1.11.1+mkl-cp35-cp35m-win_amd64.whl
  • pip install Pmw-2.0.1-py3-none-any.whl
  • pip install pymol-1.8.3.2-cp35-cp35m-win_amd64.whl
  • pip install pymol_launcher-1.0-cp35-cp35m-win_amd64.whl
BIOGEM
5. Open the directory (C:\Python35) and double-click the binary file PyMOL.exe to launch PyMOL v1.8.3.2 software.
BIOGEM

Thursday, December 4, 2014

Technical Questions


1.You have been asked to review instructions in a .PDF file, but the file doesn't open. What is a typical troubleshooting step for this issue?

Reinstall or update Adobe Reader
Ask for another copy of the file
Open the file with Notepad
Convert the file to a different format

Sunday, November 30, 2014

How to upgrade phpMyAdmin in XAMPP to latest?

Most of the windows users choose XAMMP to install Apache distribution containing MySQL, PHP, phpMyAdmin, and Perl. But, if you try to update any one of the softwares, you may face difficulties. Either you must have to install the latest version of XAMPP (or) you must update the software and configure the web server manually. In such case, we may either loss the data (or) it may remain nonfunctional. So it is safe to take backup of whole files, before trying to install manually.

Thursday, May 8, 2014

Hydrophobicity Plot using BioPython

Hydrophobicity is the property of being water repellent, tending to repel and not absorb water. Calculation of hydrophobicity in proteins is important in identifying its various features. This can be membrane spanning regions, antigenic sites, exposed loops or buried residues. Usually, these calculations are shown as a plot along the protein sequence, making it easy to identify the location of potential protein features. The hydrophobicity is calculated by sliding a fixed size window (of an odd number) over the protein sequence. At the central position of the window, the average hydrophobicity of the entire windows is plotted.

Friday, February 21, 2014

Plotting Graph by Keyboard Input using Python

2D Smooth Graph

Introduction to 2D Smooth Graph

Connecting line between two points (x1, y1) and (x2, y2) is known as a graph. A non-uniform cartesian co-ordinates points will generate a rigid line, which looks ugly. In Python, a rigid graph can be regenerated into a smooth graph by interpolating more points using SciPy module. SciPy (Scientific Python library) generates more sub-points based on the input array values to form a smooth curve. In this program, I have used input() function to get n number of points (x, y) from the user through keyboard (screenshot is given in the bottom) and store it to arrays. The co-ordinates points used in the program are (1, 2), (2, 5), (3, 3), (4, 6), (5, 7), (6, 2), (7, 10), (8, 5), (9, 6), and (10, 3).

Program Implementation

In this tutorial, I have used Python 3.5.2 (64-bit) software, and 7 modules: MatPlotLib 2.0.2, PyParsing 2.2.0, Python-DateUtil 2.6.1, PyTZ 2017.2, SetupTools 36.2.0, Cycler 0.10.0, SciPy 0.19.1, and NumPy-MKL 1.13.1 implemented in Windows 10 Enterprise (64-bit) operating system. The 8 modules are chosen based on the compatibility of Python version and OS bit.

Source Code

import scipy.interpolate as inter
import numpy as np
import matplotlib.pyplot as plt

p, h = list(), list()

print("Pulse vs Height Graph:-\n")
n = input("How many records? ")

print("\nEnter the pulse rate values: ")
for i in range(int(n)):
 pn = input()
 p.append(int(pn))
 x = np.array(p)

print("\nEnter the height values: ")
for i in range(int(n)):
 hn = input()
 h.append(int(hn))
 y = np.array(h)

print("\nPulse vs Height graph is generated!")

z = np.arange(x.min(), x.max(), 0.01)
s = inter.InterpolatedUnivariateSpline(x, y)

plt.plot (x, y, 'b.')
plt.plot (z, s(z), 'g-')
plt.xlabel('Pulse')
plt.ylabel('Height')
plt.title('Pulse vs Height Graph')
plt.show()

Command Prompt

Command Window


Polynomial Graph using Python

Polynomial Graph

Introduction to Polynomial Graph

Polynomial curve a is smooth and continues line of graph, connected by a series of co-ordinates calculated using a polynomial equation (For example, y = f(x), where f(x) = Ax2 + Bx + C). In this program, I have used a polynomial equation y = 3x2 + 4x + 2 with x values range from 0 to 5. The program generated co-ordinate points (x, y) in the graph will be (0, 2), (1, 9), (2, 22), (3, 41), (4, 66), and (5, 97).

Program Implementation

In this tutorial, I have used Python 3.5.2 (64-bit) software, and 7 modules: MatPlotLib 2.0.2, PyParsing 2.2.0, Python-DateUtil 2.6.1, PyTZ 2017.2, SetupTools 36.2.0, Cycler 0.10.0, and NumPy-MKL 1.13.1 implemented in Windows 10 Enterprise operating system. The 7 modules are chosen based on the compatibility of Python and OS version and bit.

Source Code

import numpy as np
import matplotlib.pyplot as plt

a = 3
b = 4
c = 2
x = np.linspace(0, 10, 256, endpoint = True)
y = (a * (x * x)) + (b * x) + c

plt.plot(x, y, '-g', label=r'$y = 3x^2 + 4x + 2$')

axes = plt.gca()
axes.set_xlim([x.min(), x.max()])
axes.set_ylim([y.min(), y.max()])

plt.xlabel('x')
plt.ylabel('y')
plt.title('Polynomial Curve')
plt.legend(loc='upper left')

plt.show()