Re: [PyMOL] set_view based on origin and a vector

2022-03-25 Thread Jared Sampson
Hi Wei - Fun problem! Not a "smart" way to do it, but I think functional, using pseudoatoms and orient to set the view angle: ``` # Create an origin pseudoatom ori_coords = [0.4017522, 23.15367207, 6.68992345] cmd.pseudoatom("ori", pos=ori_coords) color red, ori show nb_spheres, ori # Second ps

[PyMOL] set_view based on origin and a vector

2022-03-25 Thread Wei Wang
Dear PyMOL community, I have a need to adjust my view point in python script. I want to achieve the following: 1. I have a origin with coordinates [ 0.4017522 23.15367207 6.68992345] 2. I have a vector/rotation axis [0.74, 0.18, -0.65] 3. I want to look directly down that vector using above orig