Answers.Body: <p>There are more R packages available that calculate GC content, for example Ape's <code>GC.content()</code> function.</p>
  
  <p>For example:</p>
  
  <pre><code>&gt; library(ape)
  &gt; data(woodmouse)
  &gt; GC.content(woodmouse)
  [1] 0.3873347
  </code></pre>
  
  <p>With a sliding window is in <code>Biostrings</code> package.</p>
  
  <pre><code>&gt; library(Biostrings) 
  &gt; DNA &lt;- DNAString("ACTGAAACCGTGGCAGTTTGAC")
  &gt; letterFrequencyInSlidingView(DNA, view.width=4,letters="CG")
  </code></pre>
  
  <p>For codon usage bias, I think <code>cubfits</code> or <code>sscu</code> packages might be useful. </p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-08-10T10:18:58.833Z
Answers.Text: Could you please [edit] your question and give an example of how the OP can use this package, what kind of results it would return, the type of input data etc? As it stands, this is more of a comment than an answer.
Answers.UserDisplayName: terdon
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-08-10T10:23:04.290Z
Answers.Text: According to ape gc.content will only give a percentage. I'm looking for the overall distribution.
Answers.UserDisplayName: AudileF
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-08-10T10:56:51.277Z
Answers.Text: The definition of [GC content](https://en.wikipedia.org/wiki/GC-content) is a percentage.
Answers.UserDisplayName: benn
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-08-10T09:58:50.333Z
Answers.LastActivityDate: 2017-08-10T11:24:02.910Z
Answers.LastEditDate: 2017-08-10T11:24:02.910Z
Answers.UserDisplayName: benn
Body: <p>I'm looking to generate data based on the DNA composition of a region of my genomes (data is incomplete genomes from HiSeq runs in fasta format). I'm looking for software which will give me sliding windows for GC content, GC skew, codon bias etc. I would like to use something which I can use with or plug into R. </p>
  
Tags: <r><software-recommendation><phylogenetics>
Title: Software recommendations - DNA composition
ThreadText: # Software recommendations - DNA composition
  
  (Asked by: username_0 on 2017-08-10)
  
  I'm looking to generate data based on the DNA composition of a region of my genomes (data is incomplete genomes from HiSeq runs in fasta format). I'm looking for software which will give me sliding windows for GC content, GC skew, codon bias etc. I would like to use something which I can use with or plug into R.
  
  **Tags:** r, software-recommendation, phylogenetics
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2017-08-10. Score: 4 | Accepted answer
  
  There are more R packages available that calculate GC content, for example Ape's `GC.content()` function.
  
  For example:
  
  ```
  > library(ape)
  > data(woodmouse)
  > GC.content(woodmouse)
  [1] 0.3873347
  
  ```
  
  With a sliding window is in `Biostrings` package.
  
  ```
  > library(Biostrings) 
  > DNA <- DNAString("ACTGAAACCGTGGCAGTTTGAC")
  > letterFrequencyInSlidingView(DNA, view.width=4,letters="CG")
  
  ```
  
  For codon usage bias, I think `cubfits` or `sscu` packages might be useful.
  
  > **Comments:**
  > **username_2**: Could you please [edit] your question and give an example of how the OP can use this package, what kind of results it would return, the type of input data etc? As it stands, this is more of a comment than an answer.  
  > **username_0**: According to ape gc.content will only give a percentage. I'm looking for the overall distribution.  
  > **username_1**: The definition of [GC content](https://en.wikipedia.org/wiki/GC-content) is a percentage.  
  
  ---
  
  