Dear All,
I would like to run the command-line software called STRUCTURE on a Linux server. I downloaded the package of the Linux command-line version (without graphical front end) available with this link: https://web.stanford.edu/group/pritchardlab/structure_software/release_versions/v2.3.4/release/structure_linux_console.tar.gz
After, I extracted the file with the command tar -zxvf structure_linux_console.tar.gz
. This resulted in a folder called console
inside of this, the program called structure
. I navigated into the folder, so I'm exactly at the place of the structure
file. Then, I tried to run it two different ways: (1) simply typing structure
after (2) I tried ./structure
but for some reason, I cannot execute the program. I also tried to use sudo
for administrative privileges but nothing. Recently, someone suggested me to run it with sh
, but in this case I receive the following error: structure: 1: structure: Syntax error: word unexpected (expecting ")")
I would like to ask for the help of experienced bioinformaticians to overcome this error. I greatly appreciate any help. Please note that I'm new to using linux/unix.
Best, Thend
You can try installing Structure with conda, or compile from source:
You will need to use
./structure
while you're inside that directory, as it wont yet be in your$PATH
.You probably need to make it executable with
chmod +x /path/to/structure
.Otherwise, you need to tell us how/why you cannot execute the program as there could be a myriad of different reasons.
General comments:
sudo
when you don't know what the code does.sh
because someone told you to when you don't know what the code does (or is written in).Dear Joe,
I tried: chmod +x /home/.../structure but nothing happens after I tried structure but it gives me structure: command not found after I tried ./structure but still nothing. It shows -bash: ./structure: No such file or directory
I can download and run the software without any issue on a Linux machine with simply
./structure
. You need to show us the exact errors you're getting, the file paths you're using and so on, else we can't really help.chmod +x
doesn't 'visibly' do anything, it just sets the permissions on the file.You still need to use
./structure
from within the directory that the file exists.I tried it that way (I was writing it in my question). I do everything in the folder where the software is. :(
endretoth : Which linux flavor are you using? I downloaded the pre-compiled executable from your link and had no issues getting it to run.
These are my commands:
could you show an ls -l of that folder?
Yes it is the following:
can you
md5sum
yourstructure
file and show us the result?It should match
2fcb2fa0314005d681340f0496924924
. It seems your error could be caused by a number of things, an incomplete download/transfer being one of them.