QUESTION about cg content of a gene

20 views
Skip to first unread message

Keyvān Karami

unread,
May 31, 2016, 12:20:19 PM5/31/16
to gen...@soe.ucsc.edu
 Hi
my question is how can i use UCSC and get some features like cg content in my sequence i want to calculate and not in 5 window span. for example, i want to know in region like chr1:2772575-2921534 whts the amount of cg content.
THANKS.

--
Regards,

Keyvan



Luvina Guruvadoo

unread,
Jun 8, 2016, 2:12:27 PM6/8/16
to Keyvān Karami, gen...@soe.ucsc.edu
Hello Keyvan,

Thank you for your question. You can do this calculation using a couple of our utilities, twoBitToFa and faCount, which you can download here: http://hgdownload.soe.ucsc.edu/admin/exe/. You will also need the following 2bit file: http://hgdownload.cse.ucsc.edu/goldenPath/hg38/bigZips/hg38.2bit

Here is the commandline calculation:
$ twoBitToFa http://hgdownload.cse.ucsc.edu/goldenPath/hg38/bigZips/hg38.2bit:chr7:2772575-2921534 stdout \
   | faCount stdin
#seq                     len     A       C       G       T      N       cpg
chr7:2772575-2921534    148959  39330   36751   35593   37285   0       2899
total                   148959  39330   36751   35593   37285   0       2899

$ bc -q
scale+=3
100*(36751+35593)/148959
48.566
If you have any further questions, please reply to gen...@soe.ucsc.edu. All messages sent to that address are archived on a publicly-accessible forum. If your question includes sensitive data, you may send it instead to genom...@soe.ucsc.edu.

Regards,
Luvina

--
Luvina Guruvadoo
UCSC Genome Browser

http://genome.ucsc.edu




--


Keyvān Karami

unread,
Jun 27, 2016, 11:01:51 AM6/27/16
to Luvina Guruvadoo, gen...@soe.ucsc.edu
Hi Luvina
Thanks for introducing, i dont know how to use the links you sent me. unfortunately the link http://hgdownload.cse.ucsc.edu/goldenPath/hg38/bigZips/hg38.2bit:chr7:2772575-2921534
NOT FOUND and do i need Linux for using that. THANK YOU.
 
--
Regards,

Keyvan 


Christopher Lee

unread,
Jun 30, 2016, 1:55:02 PM6/30/16
to Keyvān Karami, Luvina Guruvadoo, gen...@soe.ucsc.edu

Hi Keyvan,

Thank you for your question about calculating the GC content of a gene.

If you are using a Mac or Linux operating system, you can download the twoBitToFa and
faCount utilities from the following directory:
http://hgdownload.soe.ucsc.edu/admin/exe/

Just select the operating system you are using and find the links for twoBitToFa
and faCount. If you are unsure as to your operating system, you can type
uname -a on a command prompt.

Once you have downloaded the utilities, you must then make them executable before you
can run them:
1. On a terminal, cd to where you downloaded the utils. If you are on a Mac,
this is most likely ~/Downloads.
2. Enter the following commands to make the utils executable:
chmod +x twoBitToFa
chmod +x faCount

Now you are ready to run the commands Luvina mentioned previously:
./twoBitToFa http://hgdownload.cse.ucsc.edu/goldenPath/hg38/bigZips/hg38.2bit:chr7:2772575-2921534 stdout | ./faCount stdin

You can now calculate a GC% using the output from the previous command. Again
from a terminal, type the following:
bc -q
scale+=3
100*((number of G's output by previous step)+(number of C's output by previous step))/(total nucleotides from previous step)

You should now have a GC percentage.

Thank you again for your inquiry and using the UCSC Genome Browser. If you have any


further questions, please reply to gen...@soe.ucsc.edu. All messages sent to that address
are archived on a publicly-accessible forum. If your question includes sensitive data, you
may send it instead to genom...@soe.ucsc.edu.

Christopher Lee
UCSC Genomics Institute


--

---
You received this message because you are subscribed to the Google Groups "UCSC Genome Browser discussion list" group.
To unsubscribe from this group and stop receiving emails from it, send an email to genome+un...@soe.ucsc.edu.

Reply all
Reply to author
Forward
0 new messages