Right-angled Artin groups and their subgroups are of great interest because of their geometric, combinatorial and algorithmic properties. It is convenient to define these groups using finite simplicial graphs. The isomorphism type of the group is uniquely determined by the graph. Moreover, many structural properties of right angled Artin groups can be expressed in terms of their defining graph. In this article we address the question of understanding the structure of a class of subgroups of right-angled Artin groups in terms of the graph. Bestvina and Brady, in their seminal work, identified studied these subgroups (now called Bestvina-Brady groups or Artin kernels) from finiteness conditions viewpoint. Unlike the right-angled Artin groups the isomorphism type of Bestvina-Brady groups is not uniquely determined by the defining graph. We prove that certain finitely presented Bestvina-Brady groups can be expressed as an iterated amalgamated product. Moreover, we show that this amalgamated product can be read off from the graph defining the ambient right-angled Artin group.